aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xconv5
1 files changed, 3 insertions, 2 deletions
diff --git a/conv b/conv
index f5d2ebc..c7b6ffb 100755
--- a/conv
+++ b/conv
@@ -11,7 +11,7 @@ IFS='
# get patch description
if [ x"$1" = x"-i" ]; then
- f=`mktemp`
+ f=`mktemp -t ${0##*/}` || exit 1
echo 'Edit patch description...' > $f
</dev/tty >/dev/tty vi $f
c=`cat $f`
@@ -34,6 +34,7 @@ while read line; do
'--- a/'*)
file=${line#--- a/}
echo -n "--- $file.orig "
+ file=$(git rev-parse --show-toplevel)/$file
echo "$(stat -x "$file")" | sed -n 's/^Access: //p' ;;
'+++ b/'*)
echo "+++ ${line#+++ b/}" ;;
@@ -68,7 +69,7 @@ if [ x"$1" = x"-i" ]; then
# write patch if it doesn't already exist
if [ -e $dir/$name ]; then
- f=`mktemp`
+ f=`mktemp -t ${0##*/}` || exit 1
echo error: $dir/$name already exists; saving to $f 1>&2
exit 1
else