Age | Commit message (Collapse) | Author |
|
If the given ID doesn't correspond to a branch in our database, we
should exit with an error.
|
|
When running:
$ git branch-list 2
we want to ensure the argument "2" in the example above is an integer.
If so, we take it to represent a branch-list ID. Otherwise an error code
should be returned.
Thanks to Peter Ho on StackOverflow for the neat Bash integer test:
https://stackoverflow.com/questions/2210349/bash-test-whether-string-is-valid-as-an-integer/19116862#19116862
|
|
Don't add existing branches to the database. We don't want any duplicate
branch names cluttering the shortcut list.
|
|
A Git add-on that stores a list of branch names and allows you to
quickly switch to any branch in the list.
This enables you to more quickly switch between branches that you're
working on or reviewing without having to either remember or look up the
beginnings of the names of the branches.
Currently provides basic functionality for saving and dropping branches
from the list, printing the list, and checking out a branch in the list.
The branch list "database" is stored in a text file in the `.git/info/`
directory local to the project. Perhaps worrisome to store an external
file in the internal Git directory, but this allows us to keep the
database local to the current project and maintain different databases
for different projects.
|