edf9988
#! /bin/bash -e
978ce46
978ce46
done=false
978ce46
if [ "x$1" = "xjames" ]; then
978ce46
    done=true
James Antill 567ec6b
    cvs=~/work/fedora/cvs/yum
978ce46
    git=~/work/rpm/private/yum
978ce46
fi
978ce46
if [ "x$1" = "xseth" ]; then
978ce46
    done=true
Seth Vidal f2d6169
    cvs=~/proj/fedora/yum/master
Seth Vidal cd4a9bb
    git=~/proj/yum/3.2.X
978ce46
fi
63f45cf
if [ "x$1" = "xvalentina" ]; then
63f45cf
    done=true
63f45cf
    cvs=~/devel/fedora/yum
63f45cf
    git=~/devel/upstream/yum
63f45cf
fi
978ce46
if ! $done; then
978ce46
63f45cf
  echo " Usage: $0 james | seth | valentina" 1>&2
978ce46
  echo "" 1>&2
978ce46
  echo "  This command copies the latest git HEAD into Fedora rawhide," 1>&2
978ce46
  echo " working out the versions automatically. It also makes the" 1>&2
978ce46
  echo " diff between HEADs as minimal as possible. " 1>&2
978ce46
  exit 1
978ce46
fi
978ce46
978ce46
cd $cvs
Seth Vidal f2d6169
ver=$(/usr/bin/fedpkg verrel | perl -lpe 's/-[^-]+$//' | sed s/\\\./-/g)
978ce46
978ce46
cd $git
James Antill 452469e
git diff -r $ver..HEAD  > $cvs/yum-HEAD.patch