Skip to content

Commit

Permalink
Document running standalone
Browse files Browse the repository at this point in the history
Fixes #32
  • Loading branch information
Mike Foley committed Dec 13, 2016
1 parent 358bdb1 commit d18d5c8
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,16 @@ To copy your default hooks into existing repos:
$ git init
```

### How can I run this standalone, like part of a CI process?

Fit Commit can be run outside of a Git hook context with a simple shell script:

```sh
$ GIT_BRANCH_NAME=branch_name COMMIT_MESSAGE_PATH=path/to/message rbenv exec ruby -rrubygems -e 'require "fit_commit"; FitCommit.run'
```

It exits with an error code if any errors are present, which will fail a build if it's part of a CI run. The configuration should be modified for CI to be more lenient, otherwise false positives will break the build too often.

### Who decided these rules?
Fit Commit aims to enforce *community standards*. The two influential guides are:

Expand Down

0 comments on commit d18d5c8

Please sign in to comment.