Skip to content

Commit

Permalink
[SDPA-2715] Adds lint step on pre-push hook (#419)
Browse files Browse the repository at this point in the history
* [SDPA-2715] Adds husky and precommit lint hook.

* [SDPA-2715] Change precommit to pre push hook

* Add unit test to pre push hook
  • Loading branch information
dylankelly authored and tim-yao committed Jul 11, 2019
1 parent 3b0a3fd commit 546c7da
Show file tree
Hide file tree
Showing 2 changed files with 1,093 additions and 239 deletions.
10 changes: 8 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"cy:open": "cypress open",
"cy:run": "cypress run -e TAGS='not @skip'",
"cy:run-smoke": "cypress run -e TAGS='@smoke'",
"lint": "eslint --ext .js,.vue . && sass-lint -qv --max-warnings 0",
"lint": "eslint --ext .js,.vue . --max-warnings 0 && sass-lint",
"lint:fix": "eslint --ext .js,.vue . --fix",
"bay:start": "docker-compose up -d",
"bay:rebuild-full": "docker-compose up -d --build --force-recreate",
Expand Down Expand Up @@ -66,6 +66,7 @@
"eslint-plugin-promise": "^3.4.0",
"eslint-plugin-standard": "^3.0.1",
"eslint-plugin-vue": "^4.0.0",
"husky": "^3.0.0",
"jest": "^24.8.0",
"jest-canvas-mock": "^2.1.0",
"jest-vue-preprocessor": "^1.5.0",
Expand All @@ -83,5 +84,10 @@
"IE 11",
"last 2 versions",
"not ie <= 8"
]
],
"husky": {
"hooks": {
"pre-push": "yarn run lint && yarn run test:unit"
}
}
}
Loading

0 comments on commit 546c7da

Please sign in to comment.