Skip to content

Instantly share code, notes, and snippets.

@blindsey
Last active August 28, 2016 15:00
Show Gist options
  • Save blindsey/5490931 to your computer and use it in GitHub Desktop.
Save blindsey/5490931 to your computer and use it in GitHub Desktop.
git post-commit to take a photo every time you commit
#!/bin/bash
EXEC=/usr/local/bin/imagesnap
if [ -x $EXEC ]; then
FILE="$HOME/gitshots/`date +%s`.jpg"
echo "Taking capture into $FILE"
$EXEC -q -w 3 $FILE
fi
exit 0
@blindsey
Copy link
Author

  1. brew install imagesnap
  2. mkdir $HOME/gitshots
  3. copy this script to .git/hooks/post-commit and make it executable
  4. make a movie: http://www.dayofthenewdan.com/projects/tlassemble
  5. profit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment