commandlinefu.com is the place to record those command-line gems that you return to again and again.
You can sign-in using OpenID credentials, or register a traditional username and password.
Subscribe to the feed for:
Print out list of all branches with last commit date to the branch, including relative time since commit and color coding.
There is 1 alternative - vote for the best!
This fixes a bug found in the other scripts which fail when a branch has the same name as a file or directory in the current directory.
Simpler and without all of the coloring gimmicks. This just returns a list of branches with the most recent first. This should be useful for cleaning your remotes.
Add this line to your ~/.gitconfig for a git alias "git brd" (i.e., brd = (br)anch+(d)ate) which sorts branches by date. Allows you to pass in limited "git branch" options such as "-r" (remote) or "-a" (all). (Note: forum added "$" prefix to command; obviously in gitconfig there is no "$" prefix.)
If you can do better, submit your command here.
You must be signed in to comment.