Skip to content

yaccz/git-branch-backup

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
bin
 
 
 
 
 
 
 
 
 
 
 
 

git-branch-backup

Creates a local backup of your branch. Usefull to do before git-rebase in case it goes wrong so you do not have to go reflog diving.

Assuming you are standing on master:

$ git branch-backup
Created backup branch 'master.backup1'

$ git branch-backup
Created backup branch 'master.backup2'

et cetera.

When you are done, you can delete backups with:

$ git branch -d master.backup{1..666}

Alias for convenience:

$ git config --global alias.bb branch-backup

Dependencies

  • zsh
  • coreutils
  • sed

For tests:

Installation

# make install

Tests

$ make check

About

Create local backup branch

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published