pre-commit hook for lint and TOC.

This commit is contained in:
Hemanth.HM 2017-12-10 12:02:38 +05:30
parent 32c1c8d6d4
commit 5dd81ec32c
2 changed files with 9 additions and 4 deletions

View file

@ -3,8 +3,7 @@
This project is a work in progress. Contributions are very welcome.
## Hard rules
* Run `npm test` to lint the code examples. Your changes must pass.
* If you add a new definition or reorder them run `npm run toc` to regenerate the table of contents.
There is a pre-commit hook that runs: `npm run test && npm run roadmarks` for linting the readme and creating the TOC.
That said, we'd like to maintain some consistency across the document.

View file

@ -20,7 +20,13 @@
"devDependencies": {
"eslint": "^3.4.0",
"eslint-config-standard": "^6.0.0",
"eslint-plugin-markdown": "^1.0.0-beta.2",
"eslint-plugin-markdown": "^1.0.0-beta.6",
"eslint-plugin-standard": "^3.0.1",
"pre-commit": "^1.2.2",
"roadmarks": "^1.6.3"
}
},
"pre-commit": [
"test",
"toc"
]
}