Use this more general tool
Tool to simplify git development with yandex.tracker
Automatically add ticket number (id) (or number and summary) to commit messages.
- get oauth token
- save OAuth token at /path-to-this-repo/oauth_token file (ignored by git for security reasons)
- add this repository to $PATH
- install commit hook by
install-tracker-commit-hook.sh
- go to your git repository
- branch.sh ISSUEID
branch 'ISSUEID' will be created with meta info obtained from st - commit
- with descriptive message
git commit -m "descriptive message"
Your actual commit message will be: ISSUEID - descriptive message - with empty message
git commit
Your actual commit message will be: ISSUEID - summary from st
- with descriptive message
- go to your git repository
- checkout existing branch
- ticket.sh ISSUEID
meta info from st is saved into git config - commit
- with descriptive message
git commit -m "descriptive message"
Your actual commit message will be: ISSUEID - descriptive message - with empty message
git commit
Your actual commit message will be: ISSUEID - summary from st
- with descriptive message
Sometimes fixed prefix must be added to branch name (due to team convention, for example).
You can achieve this:
/path-to-this-repo/bin/set-branch-name-prefix.sh feature/
After that, if you create branch by
branch.sh ISSUEID
name of newly create branch will be equal to 'feature/ISSUEID'
Custom prefix name is defined at repository level.