Created
November 24, 2014 06:22
-
-
Save dahlbyk/2527f98b919500cb6ae5 to your computer and use it in GitHub Desktop.
Git Demo Aliases
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To start a demo between <start-ref> and <end-ref> (default = HEAD): | |
# git demo <start-ref> [<end-ref>] | |
# To step through commits toward <end-ref>: | |
# git next | |
[alias] | |
demo = !sh -c 'git update-ref DEMO_HEAD $(git rev-parse ${2-HEAD}) && git checkout -fq $1~0' - | |
next = !sh -c 'git checkout -fq $(git log ..DEMO_HEAD --pretty=format:"%H" | tail -n1)' - |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment