1 unstable release
0.1.0 | Apr 27, 2022 |
---|
#1843 in Development tools
9KB
200 lines
branchify
Git branch name helper written in Rust.
Usage
Pass a ticket number and summary separated by a tab character via stdin and receive a feature branch name.
# command
echo "FOO-123\tThis is a ticket" | branchify
#output
feature/FOO-123-this-is-a-ticket
Specifying a branch type
# command
echo "FOO-123\tThis is a ticket" | branchify -t hotfix
#output
hotfix/FOO-123-this-is-a-ticket
With a prefix before the branch type
# command
echo "FOO-123\tThis is a ticket" | branchify -p adam
#output
adam/feature/FOO-123-this-is-a-ticket
The branch name will also be truncated to 40 characters
# command
echo "FOO-123\tThis ticket has a longer name"| branchify
#output
feature/FOO-123-this-ticket-has-a-longer
Used in conjunction with jira-cli
and fzf
# command
git checkout -b $(jira issue list --plain --columns key, summary | fzf | branchify)
Dependencies
~2.2–3MB
~55K SLoC