Fixed bug 506812. It requested that I update the URL/Source0 fields since

they were not quite operational anymore.
This commit is contained in:
Andy Gospodarek 2009-10-19 21:29:15 +00:00
parent 89cfc0ee11
commit d9cccc18f3
4 changed files with 22 additions and 687 deletions

View File

@ -1 +1 @@
wiggle-0.6.tar.gz
wiggle-1c5bfa7ce4de088e3b942463bb11cdc553a92b97.tar.gz

View File

@ -1 +1 @@
1884607cdebaf730737cb99b2909219b wiggle-0.6.tar.gz
7244cf7441c7f54c52f2cdc97fa9f268 wiggle-1c5bfa7ce4de088e3b942463bb11cdc553a92b97.tar.gz

View File

@ -1,678 +0,0 @@
--- wiggle-0.6.orig/ANNOUNCE
+++ wiggle-0.6/ANNOUNCE
@@ -1,4 +1,4 @@
-ANNOUNCE: wiggle - a tools for applying patches with conflicts
+ANNOUNCE: wiggle - a tool for applying patches with conflicts
I am pleased to announce the first public release of 'wiggle'.
@@ -7,7 +7,7 @@
Wiggle will always apply all changes in the patch to the original.
If it cannot find a way to cleanly apply a patch, it inserts it
-in the original in a manner similar to 'merge', and report an
+in the original in a manner similar to 'merge', and reports an
unresolvable conflict. Such a conflict will look like:
<<<<<<<
@@ -19,9 +19,9 @@
Some text that is the result of the patch
>>>>>>>
-with the meaning that the "text that the patch
-changes" was expected somewhere in the "text from the original
-file" and should be replaced with "the result of the patch".
+with the meaning that the "text that the patch changes"
+was expected somewhere in the "text from the original file"
+and should be replaced with "the result of the patch".
wiggle analyses the file and the patch in terms of words rather than
whole lines and so is able to find matches that patch is
--- wiggle-0.6.orig/bestmatch.c
+++ wiggle-0.6/bestmatch.c
@@ -346,7 +346,10 @@
int pa,pb;
pa=pb=0;
- for (b=1; b<cnt; b++) {
+ if (a1.elcnt == 0 && a2.elcnt == 0) return;
+
+ for (b=1; b<cnt; b++)
+ if (best[b].val>0) {
#if 0
printf("best %d,%d %d,%d\n",
best[b].xlo,best[b].ylo,
--- wiggle-0.6.orig/dotest
+++ wiggle-0.6/dotest
@@ -34,47 +34,47 @@
case $base in
script ) ./script ;;
diff ) if [ -f new ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dw orig new | diff -u diff - ; xit=$?
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dwp1 orig patch | diff -u diff - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -dw orig new | diff -u diff - ; xit=$?
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -dwp1 orig patch | diff -u diff - ; xit=$?
fi
;;
ldiff ) if [ -f new ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dl orig new | diff -u ldiff - ; xit=$?
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dlp1 orig patch | diff -u ldiff - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -dl orig new | diff -u ldiff - ; xit=$?
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -dlp1 orig patch | diff -u ldiff - ; xit=$?
fi
;;
- reldiff ) /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dl patch | diff -u reldiff - ; xit=$?
+ reldiff ) /usr/bin/time -o .time -f '%U' $WIGGLE -dl patch | diff -u reldiff - ; xit=$?
;;
- rediff ) /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -dw patch | diff -u rediff - ; xit=$?
+ rediff ) /usr/bin/time -o .time -f '%U' $WIGGLE -dw patch | diff -u rediff - ; xit=$?
;;
merge ) if [ -f patch ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -m orig patch | diff -u merge - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -m orig patch | diff -u merge - ; xit=$?
elif [ -f new ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -m orig new new2 | diff -u merge - ; xit=$?
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -m orig | diff -u merge - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -m orig new new2 | diff -u merge - ; xit=$?
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -m orig | diff -u merge - ; xit=$?
fi
;;
replace ) cp orig orig.tmp
if [ -f patch ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -mr orig.tmp patch
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -mr orig.tmp new new2
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -mr orig.tmp patch
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -mr orig.tmp new new2
fi
diff -u merge orig.tmp ; xit=$?
rm orig.tmp orig.tmp.porig
;;
lmerge ) if [ -f patch ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -ml orig patch | diff -u lmerge - ; xit=$?
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -ml orig new new2 | diff -u lmerge - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -ml orig patch | diff -u lmerge - ; xit=$?
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -ml orig new new2 | diff -u lmerge - ; xit=$?
fi
;;
wmerge ) if [ -f patch ]
- then /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -mw orig patch | diff -u wmerge - ; xit=$?
- else /usr/bin/time --quiet -o .time -f '%U' $WIGGLE -mw orig new new2 | diff -u wmerge - ; xit=$?
+ then /usr/bin/time -o .time -f '%U' $WIGGLE -mw orig patch | diff -u wmerge - ; xit=$?
+ else /usr/bin/time -o .time -f '%U' $WIGGLE -mw orig new new2 | diff -u wmerge - ; xit=$?
fi
;;
esac
if [ $xit = 0 ]; then msg=SUCCEEDED; else msg=FAILED; fi
- echo $path $msg `cat .time 2> /dev/null`
+ echo $path $msg `grep -v 'Command exited' .time 2> /dev/null`
rm -f .time
exit $xit
)
--- wiggle-0.6.orig/extract.c
+++ wiggle-0.6/extract.c
@@ -207,7 +207,7 @@
lineno++;
switch(state) {
case 0:
- if (len>8 &&
+ if (len>=8 &&
strncmp(cp, "<<<<<<<", 7)==0 &&
(cp[7] == ' ' || cp[7] == '\n')
) {
@@ -222,7 +222,7 @@
}
break;
case 1:
- if (len>8 &&
+ if (len>=8 &&
strncmp(cp, "|||||||", 7)==0 &&
(cp[7] == ' ' || cp[7] == '\n')
) {
@@ -232,7 +232,7 @@
copyline(&r1, &cp, end);
break;
case 2:
- if (len>8 &&
+ if (len>=8 &&
strncmp(cp, "=======", 7)==0 &&
(cp[7] == ' ' || cp[7] == '\n')
) {
@@ -242,7 +242,7 @@
copyline(&r2, &cp, end);
break;
case 3:
- if (len>8 &&
+ if (len>=8 &&
strncmp(cp, ">>>>>>>", 7)==0 &&
(cp[7] == ' ' || cp[7] == '\n')
) {
--- wiggle-0.6.orig/merge.c
+++ wiggle-0.6/merge.c
@@ -422,6 +422,15 @@
if (c1[p->c1].len == 0 ||
a < c1[p->c1].a + c1[p->c1].len) {
p->in_a = 0;
+ /*
+ * if we've slid, make sure not to skip over
+ * the stuff in c2.
+ */
+ if(slid && p->c2 != -1 && c2[p->c2].a == b &&
+ c2[p->c2].b > c2[p->c2].a) {
+ c -= c2[p->c2].b - c2[p->c2].a;
+ }
+
p->pos = c;
slid = 1;
goto retry;
--- wiggle-0.6.orig/p
+++ wiggle-0.6/p
@@ -89,7 +89,7 @@
forget_one()
{
- if cmp -s "$1" "$1~current~" && cmp -s "$1" "$1~orig~"
+ if true # || cmp -s "$1" "$1~current~" && cmp -s "$1" "$1~orig~"
then
rm -f "$1~current~" "$1~orig~"
chmod -w "$1"
@@ -140,18 +140,23 @@
{
>> .patches/files
while read file
- do eval $1 $file
+ do eval $1 $file $2
done < .patches/files
}
diff_one()
{
- if cmp -s "$1~current~" "$1"
+ if cmp -s "$1~current~" "$1" || [ ! -f "$1" -a ! -f "$1~current~" ]
then :
else
echo
echo "diff ./$1~current~ ./$1"
- diff --show-c-function -u ./$1~current~ ./$1
+ if [ " $2" = " -R" ]
+ then
+ diff -N --show-c-function -u ./$1 ./$1~current~
+ else
+ diff -N --show-c-function -u ./$1~current~ ./$1
+ fi
fi
}
@@ -168,16 +173,17 @@
commit_one()
{
- rm -f "$1~current~"
+ rm -f "$1~current~"
+ if [ -f "$1" ] ; then
mv "$1" "$1~current~"
- cp "$1~current~" $1
+ cp -p "$1~current~" $1
chmod u+w $1
+ fi
}
discard_one()
{
- rm -f "$1"
- cp "$1~current~" $1
+ cmp -s "$1~current~" $1 || { rm -f "$1" ; cp "$1~current~" $1; }
chmod u+w $1
}
@@ -188,14 +194,19 @@
mv "$1.tmp" "$1~current~"
}
+CERT='Signed-off-by: Neil Brown <neilb@suse.de>'
make_diff()
{
{
[ -s .patches/status ] && echo "Status: `cat .patches/status`"
+ [ -s .patches/notes ] && { echo; cat .patches/notes ; }
+ if grep -F "$CERT" .patches/notes > /dev/null 2>&1
+ then :
+ else echo "$CERT"
+ fi
echo
- [ -s .patches/notes ] && { cat .patches/notes ; echo; }
- all_files diff_one > .patches/tmp
- echo " ----------- Diffstat output ------------"
+ all_files diff_one $1 > .patches/tmp
+ echo "### Diffstat output"
diffstat -p0 2> /dev/null < .patches/tmp
cat .patches/tmp
[ -s .patches/tmp ] || rm .patches/patch
@@ -218,20 +229,25 @@
new=${new#1}
mv .patches/patch $dir/$new$name
}
-
+
find_prefix()
{
# set "prefix" to number for -pn by looking at first file in given patch.
- file=`lsdiff $1 | head -1`
+ n=${2-1}
+ file=`lsdiff $1 | head -$n | tail -1`
orig=$file
prefix=0
- while [ -n "$file" -a ! -f "$file" ]
+ while [ \( -n "$file" -a ! -f "$file" \) -o " $file" != " ${file#/}" ]
do
file=`expr "$file" : '[^/]*/\(.*\)'`
prefix=`expr $prefix + 1`
done
if [ -z "$file" ]
- then echo "Cannot find $orig" >&2 ; exit 1;
+ then echo "Cannot find $orig" >&2
+ if [ $n -gt 4 ]
+ then exit 2;
+ else find_prefix "$1" $[n+1]
+ fi
fi
if [ " $orig" != " $file" ]
then
@@ -246,11 +262,12 @@
awk '
BEGIN { head= 1; blanks=0 ; }
head == 1 && ( $1 == "Status:" || $0 == "" ) {
- next;
+ next;
}
{ head = 0; }
$0 == "" { blanks++; next; }
$0 ~ /^ *---/ { exit }
+ $0 ~ /^###/ { exit }
{ while (blanks > 0) {
blanks--; print "";
}
@@ -304,15 +321,20 @@
if [ ! -f "$pfile" ]
then echo >&2 "Cannot find unique patch '$1' - found: $pfile"; exit 1;
fi
- ${PAGER-less} $pfile;
+ if grep -s '^+.*[ ]$' $pfile > /dev/null
+ then
+ ${PAGER-less -p '^\+.*[ ]$'} $pfile
+ else
+ ${PAGER-less} $pfile
+ fi
;;
-
+
all )
all_files diff_one_orig
;;
status | name )
case $# in
- 1 )
+ 1 )
get_meta
if [ $cmd = name ] ; then
if [ -n "$name" ]; then
@@ -352,6 +374,11 @@
then :
else echo >&2 No patch to $cmd ; exit 1
fi
+ if grep -s '^+.*[ ]$' .patches/patch > /dev/null
+ then
+ echo >&2 remove trailing spaces/tabs first !!
+# exit 1
+ fi
if [ -s .patches/to-resolv ]
then echo "Please resolve outstanding conflicts first with 'p resolve'"
exit 1
@@ -412,7 +439,7 @@
make_diff
get_meta
if [ -s .patches/patch ]
- then
+ then
echo >&2 Patch $name already open - please commit; exit 1;
fi
if [ $# -eq 0 ]
@@ -473,13 +500,13 @@
*/* ) echo >&2 "Only local patches can have been included"; exit 1 ;;
*) pfile=`echo .patches/removed/*$1*`
esac
- if [ ! -f "$pfile" ]
+ if [ ! -f "$pfile" ]
then echo >&2 "Cannot find unique patch '$1' - found $pfile"; exit 1
fi
echo "Using $pfile..."
# make sure patch applies in reverse
- if patch -s --fuzz=0 --dry-run -f -p0 -R < "$pfile"
+ if patch -s --fuzz=0 -l --dry-run -f -p0 -R < "$pfile"
then echo "Yep, that seems to be included"
elif [ -n "$force" ]
then echo "It doesn't apply reverse-out cleanly, but you asked for it..."
@@ -490,6 +517,99 @@
save_patch included $name
echo "Moved to $new$name"
;;
+ review )
+ # there are some patches in .removed that may be included in the current source
+ # we try to backout each one. If it backs out successfully, we move it to
+ # .reviewed and conitnue, else we abort
+ # Once this has been done often enough, 'reviewed' should be run to
+ # move stuff to 'included' and to revert those patches
+ force=
+ if [ " $1" = " -f" ] ; then
+ force=yes; shift
+ fi
+ make_diff; get_meta
+ if [ -s .patches/path ]
+ then
+ echo >&2 Patch $name already open, please deal with it; exit 1;
+ fi
+ if [ $# -eq 0 ]
+ then
+ echo "Pending patches are:"
+ ls .patches/removed
+ exit 0;
+ fi
+ if [ $# -ne 1 ]
+ then
+ echo >&2 "Usage: p review patchname"; exit 1
+ fi
+ case $1 in
+ */* ) echo >&2 "Only local patches can have been included"; exit 1 ;;
+ *) pfile=`echo .patches/removed/*$1*`
+ esac
+ if [ ! -f "$pfile" ]
+ then echo >&2 "Cannot find unique patch '$1' - found $pfile"; exit 1
+ fi
+ echo "Starting from $pfile..."
+ found=
+ for fl in .patches/removed/*
+ do
+ if [ " $fl" = " $pfile" ]; then found=yes ; fi
+ if [ -n "$found" ]; then
+ echo Checking $fl
+ find_prefix "$fl"
+ lsdiff --strip=$prefix "$fl" | grep -v 'file.*changed' | while read a b
+ do check_out $a
+ done
+ if patch -s --fuzz=0 --dry-run -f -p$prefix -R < "$fl"
+ then echo Looks good..
+ elif [ -n "$force" ]
+ then echo "It doesn't backout cleanly, but you asked for it..."
+ cp $fl .patches/last-backed
+ else echo "Patch won't back out, sorry"
+ exit 1
+ fi
+ patch --fuzz=0 -f -p$prefix -R < "$fl" | tee .patches/tmp
+ sed -n -e '2q' -e 's/^Status: *//p' $fl > .patches/status
+ base=${fl##*/}
+ base=${base##[0-9][0-9][0-9]}
+ base=${base##patch-?-}
+ [ -s .patches/name ] || echo $base > .patches/name
+ extract_notes $fl >> .patches/notes
+ rm -f .patches/wiggled
+ sed -n -e 's/.*saving rejects to file \(.*\).rej/\1/p' .patches/tmp |
+ while read file
+ do echo Wiggling $file.rej into place
+ rm -f $file.porig
+ > .patches/wiggled
+ wiggle --replace --merge $file $file.rej ||
+ echo $file >> .patches/to-resolve
+ done
+
+ mv $fl .patches/patch
+ save_patch reviewed $base
+ if [ -f .patches/wiggled ]
+ then echo 'Some wiggling was needed. Please review and commit'
+ exit 0
+ fi
+ p commit || exit 1
+ fi
+ done
+ ;;
+
+ reviewed )
+ # all the currently applied patches are patches that have been
+ # reviewed as included.
+ # rip them out and stick them (reversed) into included.
+ while p open last
+ do
+ make_diff -R
+ get_meta
+ save_patch included "$name"
+ echo Saved as "$new$name"
+ all_files discard_one
+ rm -f .patches/name .patches/status .patches/notes
+ done
+ ;;
list )
echo "Applied patches are:"
ls .patches/applied
@@ -530,7 +650,7 @@
then echo >&2 "Cannot find unique patch '$1' - found: $pfile"; exit 1
fi
find_prefix "$pfile"
- lsdiff --strip=$prefix "$pfile" | grep -v 'file.*changed' | while read a b
+ lsdiff --strip=$prefix "$pfile" | grep -v 'file.*changed' | while read a b
do check_out $a
done
# lets see if it applies cleanly
@@ -566,7 +686,7 @@
;;
publish )
- name=`date -u +%Y-%m-%d:%H`
+ name=`date -u +%Y-%m-%d-%H`
if [ -d .patches/dest ]
then : good
else echo >&2 No destination specified at .patches/dest ; exit 1;
@@ -580,7 +700,7 @@
if [ -f .patches/get-version ] ;
then ./.patches/get-version > $target/version
fi
- [ -f .config ] && cp .config $target
+ [ -f .config ] && cp .config $target
cp .patches/applied/* $target
mkdir $target/misc
cp 2> /dev/null .patches/removed/* $target/misc || rmdir $target/misc
@@ -596,6 +716,60 @@
openall )
while p open last && p discard ; do : ; done
;;
+ recommit )
+ make_diff
+ get_meta
+ if [ -s .patches/patch ]
+ then
+ echo >&2 Patch $name already open - please commit ; exit 1;
+ fi
+ if [ $# -eq 0 ]
+ then
+ echo "Unapplied patches are:"
+ ls .patches/removed
+ exit 0
+ fi
+ if [ $# -ne 1 ]
+ then echo >&2 "Usage: p recommit patchname"; exit 1
+ fi
+ case $1 in
+ last ) pfile=`ls -d .patches/removed/[0-9]* | tail -1` ; echo last is "$pfile";;
+ */* ) pfile=$1 ;;
+ * ) pfile=`echo .patches/removed/*$1*`
+ esac
+ if [ ! -f "$pfile" ]
+ then echo >&2 "Cannot find unique patch '$1' - found: $pfile"; exit 1
+ fi
+ while [ -s "$pfile" ] &&
+ p apply last && p commit ; do : ; done
+ ;;
+ decommit )
+ make_diff
+ get_meta
+ if [ -s .patches/patch ]
+ then
+ echo >&2 Patch $name already open - please commit ; exit 1;
+ fi
+ if [ $# -eq 0 ]
+ then
+ echo "Applied patches are:"
+ ls .patches/applied
+ exit 0
+ fi
+ if [ $# -ne 1 ]
+ then echo >&2 "Usage: p decommit patchname"; exit 1
+ fi
+ case $1 in
+ last ) pfile=`ls -d .patches/applied/[0-9]* | tail -1` ; echo last is "$pfile";;
+ */* ) pfile=$1 ;;
+ * ) pfile=`echo .patches/applied/*$1*`
+ esac
+ if [ ! -f "$pfile" ]
+ then echo >&2 "Cannot find unique patch '$1' - found: $pfile"; exit 1
+ fi
+ while [ -s "$pfile" ] &&
+ p open last && p discard ; do : ; done
+ ;;
snapshot )
all_files snap_one
;;
@@ -626,6 +800,12 @@
cd .patches/SOURCE && bk pull
;;
update )
+ make_diff
+ get_meta
+ if [ -s .patches/patch ]
+ then
+ echo >&2 Patch $name already open - please commit; exit 1;
+ fi
p openall && p clean &&
(cd .patches/SOURCE ; bk export -tpatch -rLATEST, ) > .patches/imported-patch &&
patch --dry-run -f -p1 < .patches/imported-patch &&
@@ -651,36 +831,86 @@
echo "Your address and other headers must be in .patches/owner"
exit 1;
fi
- cnt=$(ls .patches/applied/???${1}* | wc -l)
- cnt=$(echo $cnt) # discard spaces
+ messid="<`date +'%Y%m%d%H%M%S'`.$$.patches@`uname -n`>"
+ cnt=0
+ for patch in .patches/applied/???${1}*
+ do
+ n=${patch##*/}
+ n=${n:0:3}
+ if [ -n "$2" ] && [ $2 -gt $n ] ; then continue; fi
+ if [ -n "$3" ] && [ $3 -lt $n ] ; then continue; fi
+ cnt=$(expr $cnt + 1 )
+ done
this=1
+ if [ $cnt -gt 1 ]
+ then
+ {
+ if [ -s .patches/owner.$1 ] ; then
+ cat .patches/owner.$1
+ else
+ cat .patches/owner
+ fi
+ echo "To: `cat .patches/maintainer`"
+ if [ -s .patches/cc ] ; then
+ while read word prefix addr
+ do if [ " $word" = " $1" ] ; then
+ echo "Cc: $addr"
+ sprefix="$prefix: "
+ fi
+ done < .patches/cc
+ fi
+ if [ $cnt = 1 ]
+ then
+ echo "Subject: [PATCH] ${sprefix}Intro"
+ else
+ echo "Subject: [PATCH 000 of $cnt] ${sprefix}Introduction"
+ fi
+ echo "Message-ID: $messid"
+ echo
+ echo PUT COMMENTS HERE
+ } > .patches/mail/000Intro
+ fi
+
for patch in .patches/applied/???${1}*
do
+ n=${patch##*/}
+ n=${n:0:3}
+ if [ -n "$2" ] && [ $2 -gt $n ] ; then continue; fi
+ if [ -n "$3" ] && [ $3 -lt $n ] ; then continue; fi
{
sprefix=
- cat .patches/owner
+ if [ -s .patches/owner.$1 ] ; then
+ cat .patches/owner.$1
+ else
+ cat .patches/owner
+ fi
echo "To: `cat .patches/maintainer`"
if [ -s .patches/cc ] ; then
while read word prefix addr
do if [ " $word" = " $1" ] ; then
- echo "Cc: $addr"
- sprefix="$prefix - "
+ echo "Cc: $addr"
+ sprefix="$prefix: "
fi
done < .patches/cc
fi
head=`sed -e '/^Status/d' -e '/^$/d' -e q $patch`
+ zerothis=$(expr $this + 1000)
if [ $cnt = 1 ]
then
- echo "Subject: [PATCH] $sprefix $head"
+ echo "Subject: [PATCH] $sprefix$head"
else
- echo "Subject: [PATCH] $sprefix$this of $cnt - $head"
+ echo "Subject: [PATCH ${zerothis#1} of $cnt] $sprefix$head"
fi
+ echo "References: $messid"
echo
- echo '### Comments for ChangeSet'
- sed -e '1,/^[^S]/d' $patch
+ if [ $cnt = 1 ] ; then
+ echo "### Comments for Changeset"
+ fi
+ sed -e '1,3d' $patch
} > .patches/mail/${patch#.patches/applied/}
this=$(expr $this + 1)
done
+ if [ -f .patches/mail/000Intro ]; then cat .patches/mail/* | sed -n -e 's/^Subject://p' >> .patches/mail/000Intro ; fi
ls .patches/mail
;;
@@ -690,7 +920,7 @@
;;
email )
- PATH=/usr/lib:/usr/sbin:$PATH
+ PATH=$HOME/bin:/usr/lib:/usr/sbin:$PATH
for i in .patches/mail/*
do
if [ -f "$i" ]
--- wiggle-0.6.orig/p.help
+++ wiggle-0.6/p.help
@@ -248,6 +248,14 @@
discarded. This is part of the preparation for incorporating
upstream changes.
+recommit
+ Usage: p recommit patchname
+
+ This command will re-apply and re-commit removed patches
+ that successfully apply until the names patch has been applied.
+ Patches are applied in reverse order, which is consistant with
+ the order in which they were removed.
+
snapshot
Usage: p snapshot

View File

@ -1,20 +1,30 @@
Name: wiggle
Version: 0.6
Release: 6%{?dist}
Release: 7%{?dist}
Summary: A tool for applying patches with conflicts
Group: Development/Tools
License: GPLv2+
URL: http://www.cse.unsw.edu.au/~neilb/source/wiggle/
Source0: http://www.cse.unsw.edu.au/~neilb/source/wiggle/%{name}-%{version}.tar.gz
Patch0: wiggle-various-changes.patch
Patch1: wiggle-fix-build.patch
URL: http://neil.brown.name/git/wiggle
Source0: wiggle-1c5bfa7ce4de088e3b942463bb11cdc553a92b97.tar.gz
Patch0: wiggle-fix-build.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: groff, time
#Requires:
# The source tarball used, is obtained by visiting the URL above and
# getting a snapshot that contains the latest sources. This can be
# done by clicking the 'snapshot' link listed on the gitweb interface
# This snapshot was the latest commit on the 'master' branch.
#
# RPM doesn't particularly like this link as a 'Source', so I'll paste
# is here for posterity:
#
# http://neil.brown.name/git?p=wiggle;a=snapshot;h=1c5bfa7ce4de088e3b942463bb11cdc553a92b97;sf=tgz
#
%description
Wiggle is a program for applying patches that 'patch' cannot apply due
to conflicting changes in the original.
@ -25,9 +35,8 @@ original in a manner similar to 'merge', and reports an unresolvable
conflict.
%prep
%setup -q
%setup -q -n wiggle
%patch0 -p1 -b .orig
%patch1 -p1 -b .orig
%build
make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}
@ -50,6 +59,10 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Mon Oct 19 2009 Andy Gospodarek <gospo@redhat.com> 0.6-7
- Updated location for wiggle sources and uploaded new source-file. [506812]
- Dropped first patch since it was now included.
* Mon Jul 27 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild