git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Quote arguments to tr in test-lib

From
Robin Rosenberg <robin.rosenberg@dewire.com>
Date
Sep 22, 2006, 22:35 UTC
Message-ID
<20060922223520.3412.15062.stgit@lathund.dewire.com>
From: Robin Rosenberg <robin.rosenberg@dewire.com>

When there are single-character filenames in the test directory, the shell tries to expand regexps meant for tr. ---

 t/test-lib.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/t/test-lib.sh b/t/test-lib.sh
index e262933..e75ad5f 100755
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -34,7 +34,7 @@ export GIT_AUTHOR_EMAIL GIT_AUTHOR_NAME
 export GIT_COMMITTER_EMAIL GIT_COMMITTER_NAME
 export EDITOR VISUAL
 
-case $(echo $GIT_TRACE |tr [A-Z] [a-z]) in
+case $(echo $GIT_TRACE |tr "[A-Z]" "[a-z]") in
 	1|2|true)
 		echo "* warning: Some tests will not work if GIT_TRACE" \
 			"is set as to trace on STDERR ! *"
Message 1 of 1 in “Quote arguments to tr in test-lib”
  1. Quote arguments to tr in test-libRobin Rosenberg, Sep 22, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.