Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Scripts for a git demo
#!/bin/sh
git ls-tree -r --name-only ${1:-master}
#!/bin/sh
mkdir -p .git/head
git config color.ui always
#!/bin/sh
watch -n 0.5 -t 'find -type f -not -path "./.git/*" | xargs tail -n +1'
#!/bin/sh
watch -n 0.5 -ct git diff
#!/bin/sh
watch -n 0.5 -ct git diff --cached
#!/bin/sh
watch -n 0.5 -t 'rm -rf .git/head/*; git ls-tree --full-tree HEAD --name-only | while read x; do git show "HEAD:$x" > ".git/head/$x"; done; cd .git/head; find -type f | xargs tail -n +1'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.