Inflight finds the ID of your currently started Pivotal Tracker story and adds it to your commit message. The story is located using the Git author's email.
Given you've started a story:
When you're ready to commit:
The story ID is ready and waiting in your commit message:
# Please enter the commit message for your changes. Lines starting # with '#' will be ignored, and an empty message aborts the commit. # On branch master # Changes to be committed: # new file: <% some changes %> # [#89688392]
Pivotal Tracker & Github allow you to easily link commits to your tracker stories. When you craft a commit message like this:
My words of wisdom [#<story-id>]
You'll see this commit linked in the activity of your story:
Download the latest release and place the binary on your path, e.g.
Alternatively if you have Go installed, run:
go get github.com/odlp/inflight
cdto the repo you'd like to configure.
Create a Git prepare commit message hook:
Edit the hook:
#!/bin/bash export TRACKER_API_TOKEN="<your-tracker-api-token>" export TRACKER_PROJECT_ID="<your-tracker-project-id>" inflight -o "$1"
Your Pivotal Tracker API key is located in Your Profile. The project ID is visible in the address bar of your browser whilst viewing the project.
Make the hook executable:
chmod +x .git/hooks/prepare-commit-msg
- The git author's email must match the email used for Pivotal Tracker.
- If you have more than one story started then the most recently updated story ID will be picked.
- Add interactive git hook setup