File tree Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ prepush () {
4
+ echo " --------------------------------------------------------"
5
+ echo " Linting"
6
+ echo " --------------------------------------------------------"
7
+ yarn lint || exit 1
8
+
9
+ echo " --------------------------------------------------------"
10
+ echo " Testing"
11
+ echo " --------------------------------------------------------"
12
+ git fetch upstream
13
+ yarn test --changedSince=upstream/master || exit 1
14
+ }
15
+
16
+ # Execute this script
17
+ if ! prepush; then
18
+ echo " ----------------------------------------------------"
19
+ echo " Error: failure in prepush script"
20
+ echo " ----------------------------------------------------"
21
+ exit 1
22
+ fi
Original file line number Diff line number Diff line change 149
149
],
150
150
"husky" : {
151
151
"hooks" : {
152
+ "commit-msg" : " commitlint -e" ,
152
153
"pre-commit" : " lint-staged" ,
153
- "pre-push" : " yarn lint" ,
154
- "commit-msg" : " commitlint -e"
154
+ "pre-push" : " ./build/prepush.sh"
155
155
}
156
156
},
157
157
"resolutions" : {
You can’t perform that action at this time.
0 commit comments