Blame scripts/get-snapshot.sh
|
Roland McGrath |
11487c5 |
#!/bin/bash
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
VER=$(tail -n1 upstream | sed s/bz2/id/)
|
|
Roland McGrath |
11487c5 |
rm -f $VER
|
|
Roland McGrath |
11487c5 |
wget -c http://www.kernel.org/pub/linux/kernel/v2.6/snapshots/$VER
|
|
Roland McGrath |
11487c5 |
SHA1=$(cat $VER)
|
|
Roland McGrath |
11487c5 |
rm -f patch-2.6.*-git*.id
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
cd ~/src/git-trees/kernel/linux-2.6
|
|
Roland McGrath |
11487c5 |
git pull
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
DIF=$(git diff $SHA1.. | wc -l)
|
|
Roland McGrath |
11487c5 |
if [ "$DIF" = "0" ]; then
|
|
Roland McGrath |
11487c5 |
echo Nothing changed.
|
|
Roland McGrath |
11487c5 |
exit
|
|
Roland McGrath |
11487c5 |
fi
|
|
Roland McGrath |
11487c5 |
TOT=$(git log | head -n1)
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
git diff $SHA1.. > ~/src/fedora/kernel/devel/git-linus-new.diff
|
|
Roland McGrath |
11487c5 |
cd ~/src/fedora/kernel/devel/
|
|
Roland McGrath |
11487c5 |
DIF=$(cmp git-linus.diff git-linus-new.diff)
|
|
Roland McGrath |
11487c5 |
if [ "$?" = "0" ]; then
|
|
Roland McGrath |
11487c5 |
echo Nothing new in git
|
|
Roland McGrath |
11487c5 |
rm -f git-linus-new.diff
|
|
Roland McGrath |
11487c5 |
exit
|
|
Roland McGrath |
11487c5 |
fi
|
|
Roland McGrath |
11487c5 |
mv git-linus-new.diff git-linus.diff
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
perl -p -i -e 's|^#ApplyPatch\ git-linus.diff|ApplyPatch\ git-linus.diff|' kernel.spec
|
|
Roland McGrath |
11487c5 |
|
|
Roland McGrath |
11487c5 |
echo "- Merge Linux-2.6 up to" $TOT > ~/src/fedora/kernel/devel/clog.tmp
|
|
Roland McGrath |
11487c5 |
cd ~/src/fedora/kernel/devel/
|
|
Roland McGrath |
11487c5 |
bumpspecfile.py kernel.spec "$(cat clog.tmp)"
|
|
Roland McGrath |
11487c5 |
rm -f clog.tmp
|
|
Roland McGrath |
11487c5 |
make clog
|