Git - quickly switch to last branch

Like the cd - command git also has a shortcut to checkout the last branch. git checkout - switches to the last checked out branch.

% git checkout -
Switched to branch 'foo'
% git checkout -
Switched to branch 'bar'
Jens Grassel Written by:

Solving problems and burning chrome for fun and profit.