about summary refs log blame commit diff stats
path: root/subx/ggdiff
blob: e2263ec2c2c4341af9005ea969cfd74fc857bccd (plain) (tree)





















                                                                              
#!/usr/bin/env zsh
# git diff a specific example's generated binary after converting through xxd.

if [ $# -eq 0 ]
then
  echo "ggdiff <target> [rev]"
  exit 1
fi

target=$1
rev=${2:-HEAD}

tmp=`mktemp`

if [[ $target == 'test'* ]]
then
  git show ${rev}:subx/teensy/$target > $tmp
  xdiff $tmp teensy/$target
else
  git show ${rev}:subx/$target > $tmp
  xdiff $tmp $target
fi