Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

A githook script to easily add stories from current iteration to check-in comments using the [Fixes #123123] form

tree: a045c40a05

Fetching latest commit…

Cannot retrieve the latest commit at this time

README.markdown

Pivotal Tracker Checkin comment githook

This is a hook you can add to a git workspace to easily add story numbers from unfinished stories in the current iteration to your check-in comments (in the format described here).

Coupled with proper SCM hooks to send commits to pivotal, this makes it easy for your check-in comments to appear in the comments for the story and to change the state of the story from the check-in.

When you invoke git commit and it opens the editor the message will include comment lines that look like this in the prepared message:

#[Fixes #12345678] This is the story description

Then you simply delete the # from any line that the checkin applies to and if the checkin does not complete the story also delete the word Fixes from the line.

How to use

  • Edit the prepare-commit-msg file and enter your pivotal tracker API token and project number in the space indicated.
  • Copy the prepare-commit-msg and xsl files to the .git/hooks directory of your workspace.

Note:

Git hook scripts are local to your workspace and are not part of any commit. If you clone a new workspace you will have to copy the githook scripts manually to the new workspace.

This has been tested and is used on OSX. Will probably work on Linux as well if you have xsltproc installed. Support for anything besides OSX is left as an exercise for the reader.

Something went wrong with that request. Please try again.