I want to run JSLint before a commit into either a Mercurial or Git repo is done.
I want this as an automatic step that is set up instead of relying on the developer (ma
For git, there are examples in the .git/hooks directory. If you just need the file names for JSLint, you could use git diff --name-only, which in my example will list the names of the files that differ from the current HEAD.
git diff --name-only
HEAD