Skip to content

Instantly share code, notes, and snippets.

@apatil
Created August 25, 2014 23:23
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save apatil/10ee788764ad6f510857 to your computer and use it in GitHub Desktop.
Save apatil/10ee788764ad6f510857 to your computer and use it in GitHub Desktop.
git-crypt-diff
#!/bin/bash
fname=$1
branch=$2
key=$3
if [ "$fname" = "-h" ]
then
echo "Usage: git-crypt-diff fname branch key"
exit 0
fi
git show ${branch}:${fname} | git-crypt smudge ${key} | diff ${fname} -
@apatil
Copy link
Author

apatil commented Aug 25, 2014

Diffs a git-crypted file against its version in a different branch.

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