Skip to content

nulogy/branj

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 

Repository files navigation

branj

Automatically check out a git branch corresponding to the name of a given JIRA ticket.

Installation

From Nulogy Homebrew Tap

If you have access to Nulogy's private homebrew tap, you can install branj directly through Homebrew:

$ brew tap nulogy/homebrew-nulogy git@github.com:nulogy/homebrew-nulogy.git
$ brew install nulogy/nulogy/branj

Manually

You can also install branj manually by running the following steps Symlink branj into any folder on your PATH.

For example:

$ mkdir ~/bin
$ echo 'export PATH=~/bin:$PATH' >> ~/.zshrc
$ ln -s "$(pwd)/branj" ~/bin/branj

Usage

$ branj <jira-ticket-number> [<base-branch>]

A wizard will walk you through configuration of the script the first time it is executed.

Options

  • -s: Add a suffix to the created branch. Example:
    $ branj -s part-two FOO-1337
    Switched to a new branch 'FOO-1337-fix-broken-things-part-two'
  • -m: Rename the current branch instead of creating a new one. Example:
    $ branj -m FOO-1337
  • -n: Output the branch name only, without checking out or creating a branch. Example:
    $ branj -n FOO-1337
    FOO-1337-fix-broken-things

Example

$ cd ~/src/foo_project
$ branj FOO-1337
Switched to a new branch 'FOO-1337-fix-broken-things'

About

Automatically check out a git branch corresponding to the name of a given JIRA ticket

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages