Skip to content

Commit 64edd73

Browse files
authored
Setup pre-commit hook to lint code (#31)
1 parent 62ceea4 commit 64edd73

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ async function deployActions({run, functionsDir, timeout, memory}) {
4141

4242
// Deploy
4343
console.log(`Deploying ${file}...`);
44+
// eslint-disable-next-line no-await-in-loop
4445
const {stdout, stderr, exitCode} = await run.command(command, {
4546
reject: false,
4647
stdout: 'ignore'

package.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,13 @@
3939
"engines": {
4040
"node": ">=12.0.0"
4141
},
42+
"husky": {
43+
"hooks": {
44+
"pre-commit": "yarn test"
45+
}
46+
},
4247
"devDependencies": {
48+
"husky": "^4.3.0",
4349
"xo": "^0.33.0"
4450
}
4551
}

0 commit comments

Comments
 (0)