git-brancher

1.1.0 • Public • Published

Git Brancher

his command lets you create a new branch easily, you can pass your branch text as the arguments and it will generate a valid branch name from it. A recommendation is to surround your text by ", so you can add line breaks into it.

It will also suggest some prefixes to add to the branch:

$ branch Project-1440 Sign up screen alignment (iOS)
! Your branch name so far:
git checkout -b WFM365-1440-Sign-up-screen-alignment-iOS
? Would you like to add a prefix? (none)
  (none)
❯ fix
  feature
  hotfix
  refactor
  chore
$ git checkout -b fix/WFM365-1440-Sign-up-screen-alignment-iOS

Installation

$ npm i -g git-brancher

Usage

You can pass your branch as the arguments:

$ branch your branch name

This will execute:

$ git checkout -b your-branch-name

You can also copy/paste your task from other place (i.e. Jira) and paste it using quotes:

$ branch "YourProject-2344
This would be the issue text (and possible description)"

Will execute:

$ git checkout -b YourProject-2344-This-would-be-the-issue-text-and-possible-description

Help

$ brancher --help

Readme

Keywords

Package Sidebar

Install

npm i git-brancher

Weekly Downloads

1

Version

1.1.0

License

MIT

Last publish

Collaborators

  • davsket