chiark / gitweb /
LANG, LC_*: Consistently set required LC_* env vars
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 19 Apr 2015 15:01:04 +0000 (16:01 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 31 May 2015 10:54:05 +0000 (11:54 +0100)
dgit
tests/tests/drs-push-rejects
tests/tests/push-newpackage

diff --git a/dgit b/dgit
index e5c8eab9a30cc69292cf912252df615549c236ca..3a79bb60b1a5bd7b884bbc91330908efa36a9a43 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -935,7 +935,7 @@ sub sshpsql ($$$) {
     my @rows;
     my @cmd = (access_cfg_ssh, $userhost,
               access_runeinfo("ssh-psql $runeinfo").
-              " export LANG=C;".
+              " export LC_MESSAGES=C; export LC_CTYPE=C;".
               " ".shellquote qw(psql -A), $dbname, qw(-c), $sql);
     printcmd(\*DEBUG,$debugprefix."|",@cmd) if $debug>0;
     open P, "-|", @cmd or die $!;
index f6f8882979e5b29ef79a089ba9915d76228fd970..df90d22c2109403ec1a257869f8ad9f92c84c8e3 100755 (executable)
@@ -86,7 +86,7 @@ for h in object type tag; do
     cat badtag.asc >>badtag
 
     set +e
-    LC_ALL=C git hash-object -w -t tag badtag >badtag.hash 2>badtag.err
+    LC_MESSAGES=C git hash-object -w -t tag badtag >badtag.hash 2>badtag.err
     rc=$?
     set -e
 
index 5d23faa8312cfaeba869a5ea7d50a57da1aa8fb5..2bfa5d5a30871cba470689348d2e9d439996d8cb 100755 (executable)
@@ -8,7 +8,7 @@ cd $p
 t-refs-same-start
 t-ref-head
 
-LANG=C t-dgit push 2>&1 \
+LC_MESSAGES=C t-dgit push 2>&1 \
        | tee /dev/stderr \
        | grep 'package appears to be new in this suite' >/dev/null