Sophie

Sophie

distrib > Mageia > 6 > armv7hl > media > core-updates-src > by-pkgid > 7544fc7e0f7ddc92dd7e2e9b7e383519 > files > 102

grub2-2.02.0-1.1.mga6.src.rpm

#!/bin/bash
# make_snapshot_patch
# Use:
# $ make_snapshot_patch

from=grub-2.02
to=a827807

rm -rf grub
if [ -e grub ]; then
cd grub
git pull
else
git clone git://git.savannah.gnu.org/grub.git
cd grub
fi

if [[ ${#to} > 0 ]]; then
 git checkout $to
fi 

desc=$(git describe)
commit=$(echo $desc | cut -d- -f3)
[[ $commit = "" ]] && commit="0"

git diff $from $to > ../$from-to-$desc.patch

cd ..