hgeditor: Fix some parameters to commands
authorRadoslaw "AstralStorm" Szkodzinski <astralstorm@gorzow.mm.pl>
Sun, 10 Jul 2005 16:00:24 -0800
changeset 663 562404de61fb4a8d32de222a59ead58b392a154a
parent 662 b55a78595ef66a273cc5462364ecb98374919e04
child 664 e1fbc1982372b66681a871e23e9c0370498f53e5
push id1
push usergszorc@mozilla.com
push dateWed, 18 Mar 2015 16:34:57 +0000
hgeditor: Fix some parameters to commands # HG changeset patch # User Radoslaw "AstralStorm" Szkodzinski <astralstorm@gorzow.mm.pl> # Node ID 341d27f865903223f8bf12382e3596167228a1c1 # Parent 5c5d1484b51a53918575a199ab8985160f0ce2d7 hgeditor: Fix some parameters to commands
hgeditor
--- a/hgeditor
+++ b/hgeditor
@@ -31,17 +31,17 @@ else
         cd "`hg root`"
         grep '^HG: changed' "$1" | cut -b 13- | while read changed; do
             hg diff "$changed" >> "$T2"
         done
     )
 
     CHECKSUM=`md5sum "$T1"`
     $EDITOR "$T1" "$T2" || cleanup_exit $?
-    echo "$CHECKSUM" | md5sum -c 2>/dev/null && cleanup_exit 0
+    echo "$CHECKSUM" | md5sum -c --status && cleanup_exit 13
     {
-        head -1 "$T1"
+        head -n 1 "$T1"
         echo
-        grep -v "^HG:" "$T1" | gpg -a -u "${HGUSER:-$EMAIL}" --clearsign
+        grep -v "^HG:" "$T1" | gpg -t -a -u "${HGUSER:-$EMAIL}" --clearsign
     } > "$T2" && mv "$T2" "$1"
     cleanup_exit $?
 fi