diff options
Diffstat (limited to 'pkgpatch')
-rwxr-xr-x | pkgpatch | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/pkgpatch b/pkgpatch new file mode 100755 index 0000000..8d68c20 --- /dev/null +++ b/pkgpatch @@ -0,0 +1,13 @@ +#!/bin/sh + +# pkgpatch -- patch but don't overwrite original files + +for orig in *.orig; do + mv -i "$orig" "${orig%.orig}".~1~ +done + +patch -Vt -F3 "$@" + +for orig in *.~1~; do + mv -i "$orig" "${orig%.~1~}".orig +done |