Skip to content

Instantly share code, notes, and snippets.

@mattfelten
Created July 25, 2014 21:53
Show Gist options
  • Save mattfelten/f4e089db01478e2d9675 to your computer and use it in GitHub Desktop.
Save mattfelten/f4e089db01478e2d9675 to your computer and use it in GitHub Desktop.
#!/bin/sh
revision_number=`git log --format="%H" -n 1`
revision_file=revision.txt
echo $revision_number > $revision_file
git add $revision_file
git commit --amend --no-edit
@mattfelten
Copy link
Author

Grab the ID of the commit that was just made and write it out to revision.txt and amend to that commit

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