Skip to content

Instantly share code, notes, and snippets.

@Deadlyelder
Created September 10, 2018 15:19
Show Gist options
  • Save Deadlyelder/0065e70e6aa14547545fa1add506c09d to your computer and use it in GitHub Desktop.
Save Deadlyelder/0065e70e6aa14547545fa1add506c09d to your computer and use it in GitHub Desktop.
GIT_EXTERAL_DIFF script
#! /bin/sh
path=$1
old_file=$2
old_hex=$3
old_mode=$4
new_file=$5
new_hex=$6
new_mode=$7
printf '%s: ' $path
diff $old_file $new_file | grep -v '^[<>-]'
@Deadlyelder
Copy link
Author

Useage

GIT_EXTERNAL_DIFF=git_get.sh git diff <git_hash>

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