Skip to content

Commit 1bbe5cf

Browse files
committed
Added a guard to bin/mkpatch to avoid overwriting existing patches.
- Legacy-Id: 14983
1 parent ff196ed commit 1bbe5cf

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

bin/mkpatch

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ if [[ $1 =~ / ]]; then die "Expected a patch name, but the first argument to $pr
111111
name=$1; shift;
112112

113113
patchfile=$progdir/../../patches/$(date +%Y-%m-%d)-$name.patch
114+
if [ -e $patchfile ]; then die "Patchfile $patchfile already exists"; fi
114115
svn diff ${CHG:+ -c $CHG} ${REV:+ -r $REV} "$@" > $patchfile
115116
less $patchfile
116117
echo ""

0 commit comments

Comments
 (0)