|
|
|
|
|
|
|
|
|
|
xen-ia64-devel
Re: [Xen-ia64-devel] Sparse tree merge-up script
Hi Alex,
This patch makes it easy to customize the run by specifying variables
on the command-line, for example:
LINUXPATH=$HOME/linux-2.6 NEWTAG=v2.6.17 sparse-merge
Aron
--- sparse-merge.agriffis 2006-05-16 12:56:26.000000000 -0400
+++ sparse-merge 2006-05-16 13:06:51.000000000 -0400
@@ -4,11 +4,11 @@
# Path to mercurial tree of upstream Linux
# WARNING: This will do an 'hg up -C' on the upstream Linux tree, you
# will lose data if there's anything there you care about.
-LINUXPATH=/tmp/linux-2.6
+: ${LINUXPATH:=/tmp/linux-2.6}
# Tag of current base upstream image for Xen files
-OLDTAG=v2.6.16
+: ${OLDTAG:=v2.6.16}
# Tag of new upstream base to go to
-NEWTAG=v2.6.16.13
+: ${NEWTAG:=v2.6.16.13}
SPARSEDIR=linux-2.6-xen-sparse
@@ -21,7 +21,7 @@
# We want the linux upsream tree to be at the OLDTAG to get the OLDTAG-Xen
diff.
# Save current revision to restore when done
cd $LINUXPATH
-OLDCSET=$(hg parents | head --lines=1 | awk '{print($2)}' | cut -f 1 -d :)
+OLDCSET=$(hg parents | awk '/^changeset:/{print($2)}' | cut -f 1 -d :)
hg up -C $OLDTAG
cd $WD
for i in $(hg manifest | awk '{print($3)}' | grep $SPARSEDIR | grep ia64); do
@@ -32,7 +32,7 @@
DIFFPATH=$(echo $i | sed -e "s,^$SPARSEDIR,$LINUXPATH,")
if [ ! -d $DIRNAME ]; then
- echo "Hmm, something bad happened parsing directory name: %i"
+ echo "Hmm, something bad happened parsing directory name: $i"
continue
fi
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|
|
|
|
|