Skip to content

Commit 22f53d2

Browse files
RodolfoSilvalucianomlima
authored andcommitted
Add husky - fix #5 (#9)
* Add husky * Update README.md closes #5
1 parent 3e0e505 commit 22f53d2

File tree

5 files changed

+8
-3
lines changed

5 files changed

+8
-3
lines changed

.npmignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
LICENSE
22
README.MD
3+
.gitignore

README.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ To inject custom scripts and remove unnecessary files.
2727
### Includes
2828

2929
- [x] ESlint (extends Airbnb) v4.19.1
30+
- [x] Husky v1.1.2
3031
- [x] Lint Staged v7.3.0
3132
- [x] Prettier v1.14.3
3233
- [x] Flow v0.84.0
@@ -38,7 +39,6 @@ To inject custom scripts and remove unnecessary files.
3839
- [x] `android:shake` - Show DEV menu
3940
- [x] `ios:install` - Run in Release mode
4041
- [x] `project:clean` - Clean project
41-
- [x] `precommit` - Run tasks before commit
4242
- [x] `prettier:check` - Check for unformatted files
4343
- [x] `prettier:all` - Format files
4444
- [x] `lint` - Run lint
@@ -50,7 +50,6 @@ To inject custom scripts and remove unnecessary files.
5050
### Roadmap
5151

5252
- [ ] Add Enzyme
53-
- [ ] Add Husky
5453

5554
### Contributing
5655

devDependencies.json

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"eslint-plugin-react": "7.11.1",
1313
"eslint-plugin-react-native": "3.5.0",
1414
"flow-bin": "0.84.0",
15+
"husky": "1.1.2",
1516
"lint-staged": "7.3.0",
1617
"prettier": "1.14.3"
1718
}

extension.json

+5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
{
2+
"husky": {
3+
"hooks": {
4+
"pre-commit": "lint-staged"
5+
}
6+
},
27
"jest": {
38
"preset": "react-native",
49
"transform": {

scripts.json

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
"android:shake": "$ANDROID_HOME/platform-tools/adb shell input keyevent 82",
66
"ios:install": "react-native run-ios --configuration Release",
77
"project:clean": "rm -Rf $TMPDIR/react-* node_modules && watchman watch-del-all && yarn cache clean && cd android && ./gradlew clean && cd .. && yarn",
8-
"precommit": "lint-staged",
98
"prettier:check": "prettier -l index.js src/**/*.js",
109
"prettier:all": "prettier --insert-pragma --write index.js src/**/*.js",
1110
"lint": "eslint --ext .js src/** ",

0 commit comments

Comments
 (0)