Patchwork [2,of,2] test-amend: fix HGEDITOR shell script to run on Windows

login
register
mail settings
Submitter Matt Harbison
Date July 14, 2017, 3 a.m.
Message ID <067229dccb405319bc51.1500001212@Envy>
Download mbox | patch
Permalink /patch/22311/
State Accepted
Headers show

Comments

Matt Harbison - July 14, 2017, 3 a.m.
# HG changeset patch
# User Matt Harbison <matt_harbison@yahoo.com>
# Date 1500001031 14400
#      Thu Jul 13 22:57:11 2017 -0400
# Node ID 067229dccb405319bc510f029663221624f21a79
# Parent  a7a929d086cfb37b63e8d6d00edc4cff7a9042b7
test-amend: fix HGEDITOR shell script to run on Windows

Windows doesn't know how to launch *.sh directly.  This workaround is used in
several other tests.

Patch

diff --git a/tests/test-amend.t b/tests/test-amend.t
--- a/tests/test-amend.t
+++ b/tests/test-amend.t
@@ -118,10 +118,10 @@ 
   > EOF
   $ chmod +x $TESTTMP/prefix.sh
 
-  $ HGEDITOR="$TESTTMP/prefix.sh" hg amend --edit -q
+  $ HGEDITOR="sh $TESTTMP/prefix.sh" hg amend --edit -q
   $ hg log -r . -T '{node|short} {desc}\n'
   298f085230c3 EDITED: NEWMESSAGE
-  $ HGEDITOR="$TESTTMP/prefix.sh" hg amend -e -m MSG -q
+  $ HGEDITOR="sh $TESTTMP/prefix.sh" hg amend -e -m MSG -q
   $ hg log -r . -T '{node|short} {desc}\n'
   974f07f28537 EDITED: MSG