contrib/sign.sh: fix handling of filenames with spaces
This commit is contained in:
parent
9449f0f5d8
commit
a3559a4d32
@ -19,22 +19,22 @@ EOHELP
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
SECRET=$1
|
SECRET="$1"
|
||||||
|
|
||||||
manifest=$2
|
manifest="$2"
|
||||||
upper=$(mktemp)
|
upper="$(mktemp)"
|
||||||
lower=$(mktemp)
|
lower="$(mktemp)"
|
||||||
|
|
||||||
awk "BEGIN { sep=0 }
|
awk "BEGIN { sep=0 }
|
||||||
/^---\$/ { sep=1; next }
|
/^---\$/ { sep=1; next }
|
||||||
{ if(sep==0) print > \"$upper\";
|
{ if(sep==0) print > \"$upper\";
|
||||||
else print > \"$lower\"}" \
|
else print > \"$lower\"}" \
|
||||||
$manifest
|
"$manifest"
|
||||||
|
|
||||||
ecdsasign $upper < $SECRET >> $lower
|
ecdsasign "$upper" < "$SECRET" >> "$lower"
|
||||||
|
|
||||||
cat $upper > $manifest
|
cat "$upper" > "$manifest"
|
||||||
echo --- >> $manifest
|
echo --- >> "$manifest"
|
||||||
cat $lower >> $manifest
|
cat "$lower" >> "$manifest"
|
||||||
|
|
||||||
rm -f $upper $lower
|
rm -f "$upper" "$lower"
|
||||||
|
Loading…
Reference in New Issue
Block a user