Git pre-commit script that lints your javascript
Shell JavaScript
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
.jshintignore
.jshintrc
MIT-LICENSE.txt
README.md
install.sh
pre-commit
reporter.js

README.md

Sgt Donowitz

What?:

It's a git pre-commit script that checks your Javascript code for errors before every commit, if it finds any issues it simply aborts the commit. Sgt-Donowitz helps you set this up in less than a minute.

Why?:

Because it's easier to maintain good code when you are forced to

How?:

from the root of your project run:

curl -s jt.io/lint | sh

Where?

Mac OS X / Unix only

What if?

If for some reason you must commit a JS file without validating/linting it you can always run a commit with the "no-verify" flag: i.e. git commit --no-verify .

However, when doing this remember that there are no flags to remove bad Karma.

More?

If you want to learn more about this, I've written a blog post in my blog here