Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
function silencing_stderr() {
$* 2>/dev/null
}
function branch_names() {
git br | awk '{print $1}' | grep -v '*' | xargs
}
for branch_name in $(branch_names)
do
echo -n "${branch_name}: "
echo -n $'\t\t' # add a tab. Tabs are special. See http://superuser.com/questions/362235/how-do-i-enter-a-literal-tab-character-in-a-bash-shell
silencing_stderr git log -n 1 $branch_name | grep "Date: " | cut -c 9- | head -1
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment