]> git.marmaro.de Git - mmh/commitdiff
I guess the -i option to sed works differently on Linux and MacOS
authorKen Hornstein <kenh@pobox.com>
Thu, 15 Mar 2012 15:55:34 +0000 (11:55 -0400)
committerKen Hornstein <kenh@pobox.com>
Thu, 15 Mar 2012 15:55:34 +0000 (11:55 -0400)
X; deal with it.

test/post/test-post-common.sh
test/post/test-post-fcc

index 7698b81cf9d37c3dc6d49556a6888cd4dd84794e..c35a5a256e83cb87f53ecd299077e87791bd80f9 100755 (executable)
@@ -37,7 +37,9 @@ test_post ()
     # compare it against our "correct" output.
     #
 
-    sed -i "" -e 's/^Date:.*/Date:/' "$1"
+    sed -i.bak -e 's/^Date:.*/Date:/' "$1"
+
+    rm -f "${1}.bak"
 
     check "$1" "$2"
 }
index b8a9419063aeaac2665840b6b2102c943e05eed2..5ade9723a31d0c5efa88aeaaa9bfab4c51c1f28f 100755 (executable)
@@ -54,8 +54,10 @@ EOF
 
 msgname=$(mhpath +inbox 11)
 
-sed -i "" -e 's/^Date:.*/Date:/' ${msgname}
+sed -i.bak -e 's/^Date:.*/Date:/' "${msgname}"
 
-check "${testname}.msg.expected" ${msgname}
+rm -f "${msgname}.bak"
+
+check "${testname}.msg.expected" "${msgname}"
 
 exit ${failed:-0}