瀏覽代碼

contrib/sign.sh: fix handling of filenames with spaces

Benny Baumann 9 年之前
父節點
當前提交
a3559a4d32
共有 1 個文件被更改,包括 16 次插入16 次删除
  1. 16 16
      contrib/sign.sh

+ 16 - 16
contrib/sign.sh

@@ -18,23 +18,23 @@ See also
 EOHELP
 	exit 1
 fi
- 
-SECRET=$1
- 
-manifest=$2
-upper=$(mktemp)
-lower=$(mktemp)
- 
+
+SECRET="$1"
+
+manifest="$2"
+upper="$(mktemp)"
+lower="$(mktemp)"
+
 awk "BEGIN    { sep=0 }
      /^---\$/ { sep=1; next }
               { if(sep==0) print > \"$upper\";
                 else       print > \"$lower\"}" \
-    $manifest
- 
-ecdsasign $upper < $SECRET >> $lower
- 
-cat  $upper  > $manifest
-echo ---    >> $manifest
-cat  $lower >> $manifest
- 
-rm -f $upper $lower
+    "$manifest"
+
+ecdsasign "$upper" < "$SECRET" >> "$lower"
+
+cat  "$upper"  > "$manifest"
+echo ---      >> "$manifest"
+cat  "$lower" >> "$manifest"
+
+rm -f "$upper" "$lower"