Legit
Installation
$ gem install legitRequires ruby >= 1.8.7
Usage
Run legit with no options to see a list of commands and options.
legit checkout
Recommended alias: lco
Fuzzy git checkout
Setting Up a catch-todos pre-commit Hook
- Add the following to
.git/hooks/pre-commitin the desired repository:
#! /bin/bash
legit catch-todos TODO- Make the hook executable (git will silently ignore your hook otherwise):
chmod +x .git/hooks/pre-commitEnable or disable catch-todos with the --enable and --disable options
legit catch-todos --disable # will not check todos until re-enabled
legit catch-todos --enable # sets it back to normal
Note: some graphical git tools may not run git hooks.
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Added some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request