Skip to content

Commit

Permalink
build: fix postinstall script causing user install errors
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Jul 13, 2017
1 parent ac3d1ea commit a7615ef
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,10 @@ After cloning the repo, run:

``` bash
$ npm install
& npm run setup
```

This will also run the `postinstall` script which links two git hooks:
The `setup` script links two git hooks:

- `pre-commit`: runs ESLint on staged files.
- `commit-msg`: validates commit message format (see below).
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"release": "bash build/release.sh",
"release:weex": "bash build/release-weex.sh",
"release:note": "node build/gen-release-note.js",
"postinstall": "node build/install-hooks.js",
"setup": "node build/install-hooks.js",
"commit": "git-cz"
},
"repository": {
Expand Down

1 comment on commit a7615ef

@eddyerburgh
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be good to keep the postinstall script in dev and delete it in the release script before publishing to npm/ pushing to github. It means there won't be any non conforming commits slipping through the cracks.

Please sign in to comment.