Skip to content

Instantly share code, notes, and snippets.

@yaotti
Created August 3, 2011 11:44
Show Gist options
  • Save yaotti/1122446 to your computer and use it in GitHub Desktop.
Save yaotti/1122446 to your computer and use it in GitHub Desktop.
仕事初めshellscript
#!/bin/sh
branch=$(git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1 /')
sha1=$(git log --since=yesterday -1 --format=%h)
echo "Start working at $(date '+%H:%M:%S')\nbranch: $branch(from:${sha1})"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment