{"thread":{"id":"36665","subject":"[PATCH 01/10] check_bindir: don't use the -a or -b option with the test command","startedAt":"2014-05-15T14:17:28Z","lastAt":"2014-05-16T19:09:29Z","messageCount":14,"participants":["Elia Pinto","Jonathan Nieder","David Aguilar","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":10},"messages":[{"id":"241663","messageId":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":null,"subject":"[PATCH 01/10] check_bindir: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:28Z","receivedAt":"2014-05-15T14:17:28Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n check_bindir |    2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/check_bindir b/check_bindir\nindex a1c4c3e..623eadc 100755\n--- a/check_bindir\n+++ b/check_bindir\n@@ -2,7 +2,7 @@\n bindir=\"$1\"\n gitexecdir=\"$2\"\n gitcmd=\"$3\"\n-if test \"$bindir\" != \"$gitexecdir\" -a -x \"$gitcmd\"\n+if test \"$bindir\" != \"$gitexecdir\" && test -x \"$gitcmd\"\n then\n \techo\n \techo \"!! You have installed git-* commands to new gitexecdir.\"\n-- \n1.7.10.4\n"},{"id":"241670","messageId":"1400163457-28285-2-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 02/10] contrib/examples/git-clone.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:29Z","receivedAt":"2014-05-15T14:17:29Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n contrib/examples/git-clone.sh |    2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/examples/git-clone.sh b/contrib/examples/git-clone.sh\nindex b4c9376..08cf246 100755\n--- a/contrib/examples/git-clone.sh\n+++ b/contrib/examples/git-clone.sh\n@@ -516,7 +516,7 @@ then\n \n \tcase \"$no_checkout\" in\n \t'')\n-\t\ttest \"z$quiet\" = z -a \"z$no_progress\" = z && v=-v || v=\n+\t\ttest \"z$quiet\" = z && test \"z$no_progress\" = z && v=-v || v=\n \t\tgit read-tree -m -u $v HEAD HEAD\n \tesac\n fi\n-- \n1.7.10.4\n"},{"id":"241664","messageId":"1400163457-28285-3-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 03/10] contrib/examples/git-commit.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:30Z","receivedAt":"2014-05-15T14:17:30Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n contrib/examples/git-commit.sh |    4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/contrib/examples/git-commit.sh b/contrib/examples/git-commit.sh\nindex 5cafe2e..934505b 100755\n--- a/contrib/examples/git-commit.sh\n+++ b/contrib/examples/git-commit.sh\n@@ -51,7 +51,7 @@ run_status () {\n \t\texport GIT_INDEX_FILE\n \tfi\n \n-\tif test \"$status_only\" = \"t\" -o \"$use_status_color\" = \"t\"; then\n+\tif test \"$status_only\" = \"t\" || test \"$use_status_color\" = \"t\"; then\n \t\tcolor=\n \telse\n \t\tcolor=--nocolor\n@@ -296,7 +296,7 @@ t,,,[1-9]*)\n \tdie \"No paths with -i does not make sense.\" ;;\n esac\n \n-if test ! -z \"$templatefile\" -a -z \"$log_given\"\n+if test ! -z \"$templatefile\" && test -z \"$log_given\"\n then\n \tif test ! -f \"$templatefile\"\n \tthen\n-- \n1.7.10.4\n"},{"id":"241665","messageId":"1400163457-28285-4-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 04/10] contrib/examples/git-merge.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:31Z","receivedAt":"2014-05-15T14:17:31Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n contrib/examples/git-merge.sh |    4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/contrib/examples/git-merge.sh b/contrib/examples/git-merge.sh\nindex 7e40f40..52f2aaf 100755\n--- a/contrib/examples/git-merge.sh\n+++ b/contrib/examples/git-merge.sh\n@@ -161,7 +161,7 @@ merge_name () {\n \t\t\treturn\n \t\tfi\n \tfi\n-\tif test \"$remote\" = \"FETCH_HEAD\" -a -r \"$GIT_DIR/FETCH_HEAD\"\n+\tif test \"$remote\" = \"FETCH_HEAD\" && test -r \"$GIT_DIR/FETCH_HEAD\"\n \tthen\n \t\tsed -e 's/\tnot-for-merge\t/\t\t/' -e 1q \\\n \t\t\t\"$GIT_DIR/FETCH_HEAD\"\n@@ -527,7 +527,7 @@ do\n \t\tgit diff-files --name-only\n \t\tgit ls-files --unmerged\n \t    } | wc -l`\n-\t    if test $best_cnt -le 0 -o $cnt -le $best_cnt\n+\t    if test $best_cnt -le 0 || test $cnt -le $best_cnt\n \t    then\n \t\tbest_strategy=$strategy\n \t\tbest_cnt=$cnt\n-- \n1.7.10.4\n"},{"id":"241671","messageId":"1400163457-28285-5-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 05/10] contrib/examples/git-repack.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:32Z","receivedAt":"2014-05-15T14:17:32Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n contrib/examples/git-repack.sh |    4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/contrib/examples/git-repack.sh b/contrib/examples/git-repack.sh\nindex f312405..96e3fed 100755\n--- a/contrib/examples/git-repack.sh\n+++ b/contrib/examples/git-repack.sh\n@@ -76,8 +76,8 @@ case \",$all_into_one,\" in\n \t\t\t\texisting=\"$existing $e\"\n \t\t\tfi\n \t\tdone\n-\t\tif test -n \"$existing\" -a -n \"$unpack_unreachable\" -a \\\n-\t\t\t-n \"$remove_redundant\"\n+\t\tif test -n \"$existing\" && test -n \"$unpack_unreachable\" && \\\n+\t\t\ttest -n \"$remove_redundant\"\n \t\tthen\n \t\t\t# This may have arbitrary user arguments, so we\n \t\t\t# have to protect it against whitespace splitting\n-- \n1.7.10.4\n"},{"id":"241672","messageId":"1400163457-28285-6-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 06/10] contrib/examples/git-resolve.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:33Z","receivedAt":"2014-05-15T14:17:33Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n contrib/examples/git-resolve.sh |    2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/examples/git-resolve.sh b/contrib/examples/git-resolve.sh\nindex 48d0fc9..70fdc27 100755\n--- a/contrib/examples/git-resolve.sh\n+++ b/contrib/examples/git-resolve.sh\n@@ -76,7 +76,7 @@ case \"$common\" in\n \t\t\t2>/dev/null || continue\n \t\t# Count the paths that are unmerged.\n \t\tcnt=$(GIT_INDEX_FILE=$G git ls-files --unmerged | wc -l)\n-\t\tif test $best_cnt -le 0 -o $cnt -le $best_cnt\n+\t\tif test $best_cnt -le 0 || test $cnt -le $best_cnt\n \t\tthen\n \t\t\tbest=$c\n \t\t\tbest_cnt=$cnt\n-- \n1.7.10.4\n"},{"id":"241669","messageId":"1400163457-28285-7-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 07/10] git-bisect.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:34Z","receivedAt":"2014-05-15T14:17:34Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n git-bisect.sh |    2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/git-bisect.sh b/git-bisect.sh\nindex af4d04c..1e0d602 100755\n--- a/git-bisect.sh\n+++ b/git-bisect.sh\n@@ -408,7 +408,7 @@ bisect_replay () {\n \tbisect_reset\n \twhile read git bisect command rev\n \tdo\n-\t\ttest \"$git $bisect\" = \"git bisect\" -o \"$git\" = \"git-bisect\" || continue\n+\t\ttest \"$git $bisect\" = \"git bisect\" || test \"$git\" = \"git-bisect\" || continue\n \t\tif test \"$git\" = \"git-bisect\"\n \t\tthen\n \t\t\trev=\"$command\"\n-- \n1.7.10.4\n"},{"id":"241666","messageId":"1400163457-28285-8-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 08/10] git-mergetool.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:35Z","receivedAt":"2014-05-15T14:17:35Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n git-mergetool.sh |    4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/git-mergetool.sh b/git-mergetool.sh\nindex 332528f..88e853f 100755\n--- a/git-mergetool.sh\n+++ b/git-mergetool.sh\n@@ -205,7 +205,7 @@ checkout_staged_file () {\n \t\t\"$(git checkout-index --temp --stage=\"$1\" \"$2\" 2>/dev/null)\" \\\n \t\t: '\\([^\t]*\\)\t')\n \n-\tif test $? -eq 0 -a -n \"$tmpfile\"\n+\tif test $? -eq 0 && test -n \"$tmpfile\"\n \tthen\n \t\tmv -- \"$(git rev-parse --show-cdup)$tmpfile\" \"$3\"\n \telse\n@@ -256,7 +256,7 @@ merge_file () {\n \tcheckout_staged_file 2 \"$MERGED\" \"$LOCAL\"\n \tcheckout_staged_file 3 \"$MERGED\" \"$REMOTE\"\n \n-\tif test -z \"$local_mode\" -o -z \"$remote_mode\"\n+\tif test -z \"$local_mode\" || test -z \"$remote_mode\"\n \tthen\n \t\techo \"Deleted merge conflict for '$MERGED':\"\n \t\tdescribe_file \"$local_mode\" \"local\" \"$LOCAL\"\n-- \n1.7.10.4\n"},{"id":"241668","messageId":"1400163457-28285-9-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 09/10] git-rebase--interactive.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:36Z","receivedAt":"2014-05-15T14:17:36Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n git-rebase--interactive.sh |    2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh\nindex 6ec9d3c..797571f 100644\n--- a/git-rebase--interactive.sh\n+++ b/git-rebase--interactive.sh\n@@ -1013,7 +1013,7 @@ then\n \tgit rev-list $revisions |\n \twhile read rev\n \tdo\n-\t\tif test -f \"$rewritten\"/$rev -a \"$(sane_grep \"$rev\" \"$state_dir\"/not-cherry-picks)\" = \"\"\n+\t\tif test -f \"$rewritten\"/$rev && test \"$(sane_grep \"$rev\" \"$state_dir\"/not-cherry-picks)\" = \"\"\n \t\tthen\n \t\t\t# Use -f2 because if rev-list is telling us this commit is\n \t\t\t# not worthwhile, we don't want to track its multiple heads,\n-- \n1.7.10.4\n"},{"id":"241667","messageId":"1400163457-28285-10-git-send-email-gitter.spiros@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-1-git-send-email-gitter.spiros@gmail.com","subject":"[PATCH 10/10] git-submodule.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:17:37Z","receivedAt":"2014-05-15T14:17:37Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"Even though POSIX.1 lists -a/-o as options to \"test\", they are\nmarked \"Obsolescent XSI\". Scripts using these expressions\nshould be converted  as follow:\n\ntest \"$1\" -a \"$2\"\n\nshould be written as:\n\ntest \"$1\" && test \"$2\"\n\nLikewise\n\ntest \"$1\" -o \"$2\"\n\nshould be written as:\n\ntest \"$1\"  test \"$2\"\n\nBut note that, in test, -a has higher precedence than -o while\n\"&&\" and \"||\" have equal precedence in the shell.\n\nThe reason for this is that the precedence rules were never well\nspecified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n\nFor example, if $x is \"=\", these work according to POSIX (it's not\nportable, but in practice it's okay):\n\n   $ test -z \"$x\"\n   $ test -z \"$x\" && test a = b\n\nbut this doesn't\n\n   $ test -z \"$x\" -a a = b\n   bash: test: too many arguments\n\nbecause it groups \"test -n = -a\" and is left with \"a = b\".\n\nSimilarly, if $x is \"-f\", these\n\n   $ test \"$x\"\n   $ test \"$x\" || test c = d\n\ncorrectly adds an implicit \"-n\", but this fails:\n\n   $ test \"$x\" -o c = d\n   bash: test: too many arguments\n\nSigned-off-by: Elia Pinto <gitter.spiros@gmail.com>\n---\nInspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\n git-submodule.sh |   14 +++++++-------\n 1 file changed, 7 insertions(+), 7 deletions(-)\n\ndiff --git a/git-submodule.sh b/git-submodule.sh\nindex b55d83a..d89e1d0 100755\n--- a/git-submodule.sh\n+++ b/git-submodule.sh\n@@ -864,7 +864,7 @@ Maybe you want to use 'update --init'?\")\"\n \t\tthen\n \t\t\tsubforce=$force\n \t\t\t# If we don't already have a -f flag and the submodule has never been checked out\n-\t\t\tif test -z \"$subsha1\" -a -z \"$force\"\n+\t\t\tif test -z \"$subsha1\" || test -z \"$force\"\n \t\t\tthen\n \t\t\t\tsubforce=\"-f\"\n \t\t\tfi\n@@ -1059,13 +1059,13 @@ cmd_summary() {\n \t\twhile read mod_src mod_dst sha1_src sha1_dst status sm_path\n \t\tdo\n \t\t\t# Always show modules deleted or type-changed (blob<->module)\n-\t\t\ttest $status = D -o $status = T && echo \"$sm_path\" && continue\n+                        ( test $status = D || test $status = T ) && echo \"$sm_path\" && continue\n \t\t\t# Respect the ignore setting for --for-status.\n \t\t\tif test -n \"$for_status\"\n \t\t\tthen\n \t\t\t\tname=$(module_name \"$sm_path\")\n \t\t\t\tignore_config=$(get_submodule_config \"$name\" ignore none)\n-\t\t\t\ttest $status != A -a $ignore_config = all && continue\n+\t\t\t\ttest $status != A && test $ignore_config = all && continue\n \t\t\tfi\n \t\t\t# Also show added or modified modules which are checked out\n \t\t\tGIT_DIR=\"$sm_path/.git\" git-rev-parse --git-dir >/dev/null 2>&1 &&\n@@ -1125,7 +1125,7 @@ cmd_summary() {\n \t\t*)\n \t\t\terrmsg=\n \t\t\ttotal_commits=$(\n-\t\t\tif test $mod_src = 160000 -a $mod_dst = 160000\n+\t\t\tif test $mod_src = 160000 && test $mod_dst = 160000\n \t\t\tthen\n \t\t\t\trange=\"$sha1_src...$sha1_dst\"\n \t\t\telif test $mod_src = 160000\n@@ -1162,7 +1162,7 @@ cmd_summary() {\n \t\t\t# i.e. deleted or changed to blob\n \t\t\ttest $mod_dst = 160000 && echo \"$errmsg\"\n \t\telse\n-\t\t\tif test $mod_src = 160000 -a $mod_dst = 160000\n+\t\t\tif test $mod_src = 160000 && test $mod_dst = 160000\n \t\t\tthen\n \t\t\t\tlimit=\n \t\t\t\ttest $summary_limit -gt 0 && limit=\"-$summary_limit\"\n@@ -1233,7 +1233,7 @@ cmd_status()\n \t\t\tsay \"U$sha1 $displaypath\"\n \t\t\tcontinue\n \t\tfi\n-\t\tif test -z \"$url\" || ! test -d \"$sm_path\"/.git -o -f \"$sm_path\"/.git\n+\t\tif test -z \"$url\" || ! test -d \"$sm_path\"/.git || test -f \"$sm_path\"/.git\n \t\tthen\n \t\t\tsay \"-$sha1 $displaypath\"\n \t\t\tcontinue;\n@@ -1402,7 +1402,7 @@ then\n fi\n \n # \"--cached\" is accepted only by \"status\" and \"summary\"\n-if test -n \"$cached\" && test \"$command\" != status -a \"$command\" != summary\n+if test -n \"$cached\" && test \"$command\" != status && test \"$command\" != summary\n then\n \tusage\n fi\n-- \n1.7.10.4\n"},{"id":"241673","messageId":"CA+EOSBmCk0y6rJL9WEKVZxVOGLDn7kDKkurX=+3gAsoHzhErtQ@mail.gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-10-git-send-email-gitter.spiros@gmail.com","subject":"Re: [PATCH 10/10] git-submodule.sh: don't use the -a or -b option with the test command","fromName":"Elia Pinto","fromEmail":"gitter.spiros@gmail.com","sentAt":"2014-05-15T14:19:36Z","receivedAt":"2014-05-15T14:19:36Z","isPatch":true,"sender":{"key":"gitter.spiros@gmail.com","avatar":"https://avatars.githubusercontent.com/u/158490?v=4"},"body":"I am very sorry : the comment is wrong. I will repost shortly.\n\nBest regards\n\n2014-05-15 16:17 GMT+02:00 Elia Pinto <gitter.spiros@gmail.com>:\n> Even though POSIX.1 lists -a/-o as options to \"test\", they are\n> marked \"Obsolescent XSI\". Scripts using these expressions\n> should be converted  as follow:\n>\n> test \"$1\" -a \"$2\"\n>\n> should be written as:\n>\n> test \"$1\" && test \"$2\"\n>\n> Likewise\n>\n> test \"$1\" -o \"$2\"\n>\n> should be written as:\n>\n> test \"$1\"  test \"$2\"\n>\n> But note that, in test, -a has higher precedence than -o while\n> \"&&\" and \"||\" have equal precedence in the shell.\n>\n> The reason for this is that the precedence rules were never well\n> specified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n>\n> For example, if $x is \"=\", these work according to POSIX (it's not\n> portable, but in practice it's okay):\n>\n>    $ test -z \"$x\"\n>    $ test -z \"$x\" && test a = b\n>\n> but this doesn't\n>\n>    $ test -z \"$x\" -a a = b\n>    bash: test: too many arguments\n>\n> because it groups \"test -n = -a\" and is left with \"a = b\".\n>\n> Similarly, if $x is \"-f\", these\n>\n>    $ test \"$x\"\n>    $ test \"$x\" || test c = d\n>\n> correctly adds an implicit \"-n\", but this fails:\n>\n>    $ test \"$x\" -o c = d\n>    bash: test: too many arguments\n>\n> Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>\n> ---\n> Inspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n>\n>  git-submodule.sh |   14 +++++++-------\n>  1 file changed, 7 insertions(+), 7 deletions(-)\n>\n> diff --git a/git-submodule.sh b/git-submodule.sh\n> index b55d83a..d89e1d0 100755\n> --- a/git-submodule.sh\n> +++ b/git-submodule.sh\n> @@ -864,7 +864,7 @@ Maybe you want to use 'update --init'?\")\"\n>                 then\n>                         subforce=$force\n>                         # If we don't already have a -f flag and the submodule has never been checked out\n> -                       if test -z \"$subsha1\" -a -z \"$force\"\n> +                       if test -z \"$subsha1\" || test -z \"$force\"\n>                         then\n>                                 subforce=\"-f\"\n>                         fi\n> @@ -1059,13 +1059,13 @@ cmd_summary() {\n>                 while read mod_src mod_dst sha1_src sha1_dst status sm_path\n>                 do\n>                         # Always show modules deleted or type-changed (blob<->module)\n> -                       test $status = D -o $status = T && echo \"$sm_path\" && continue\n> +                        ( test $status = D || test $status = T ) && echo \"$sm_path\" && continue\n>                         # Respect the ignore setting for --for-status.\n>                         if test -n \"$for_status\"\n>                         then\n>                                 name=$(module_name \"$sm_path\")\n>                                 ignore_config=$(get_submodule_config \"$name\" ignore none)\n> -                               test $status != A -a $ignore_config = all && continue\n> +                               test $status != A && test $ignore_config = all && continue\n>                         fi\n>                         # Also show added or modified modules which are checked out\n>                         GIT_DIR=\"$sm_path/.git\" git-rev-parse --git-dir >/dev/null 2>&1 &&\n> @@ -1125,7 +1125,7 @@ cmd_summary() {\n>                 *)\n>                         errmsg=\n>                         total_commits=$(\n> -                       if test $mod_src = 160000 -a $mod_dst = 160000\n> +                       if test $mod_src = 160000 && test $mod_dst = 160000\n>                         then\n>                                 range=\"$sha1_src...$sha1_dst\"\n>                         elif test $mod_src = 160000\n> @@ -1162,7 +1162,7 @@ cmd_summary() {\n>                         # i.e. deleted or changed to blob\n>                         test $mod_dst = 160000 && echo \"$errmsg\"\n>                 else\n> -                       if test $mod_src = 160000 -a $mod_dst = 160000\n> +                       if test $mod_src = 160000 && test $mod_dst = 160000\n>                         then\n>                                 limit=\n>                                 test $summary_limit -gt 0 && limit=\"-$summary_limit\"\n> @@ -1233,7 +1233,7 @@ cmd_status()\n>                         say \"U$sha1 $displaypath\"\n>                         continue\n>                 fi\n> -               if test -z \"$url\" || ! test -d \"$sm_path\"/.git -o -f \"$sm_path\"/.git\n> +               if test -z \"$url\" || ! test -d \"$sm_path\"/.git || test -f \"$sm_path\"/.git\n>                 then\n>                         say \"-$sha1 $displaypath\"\n>                         continue;\n> @@ -1402,7 +1402,7 @@ then\n>  fi\n>\n>  # \"--cached\" is accepted only by \"status\" and \"summary\"\n> -if test -n \"$cached\" && test \"$command\" != status -a \"$command\" != summary\n> +if test -n \"$cached\" && test \"$command\" != status && test \"$command\" != summary\n>  then\n>         usage\n>  fi\n> --\n> 1.7.10.4\n>\n"},{"id":"241686","messageId":"20140515155821.GA27279@google.com","threadId":"36665","inReplyTo":"1400163457-28285-10-git-send-email-gitter.spiros@gmail.com","subject":"Re: [PATCH 10/10] git-submodule.sh: don't use the -a or -b option with the test command","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2014-05-15T15:58:22Z","receivedAt":"2014-05-15T15:58:22Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Elia Pinto wrote:\n\n> Even though POSIX.1 lists -a/-o as options to \"test\", they are\n> marked \"Obsolescent XSI\". Scripts using these expressions\n> should be converted  as follow:\n[... many lines snipped ...]\n\nThis is a very long description, and it doesn't leave me excited by\nthe change.\n\nIs there some potential bug this prevents, or is it just a style\nfix?  If the latter, do we have a way of checking for new examples\nof the same thing to avoid having to repeat the same patch again in\nthe future?\n\nAre there any platforms that were broken which this fixes?  Even\nposh seems to understand -a and -o.\n\nNowadays Documentation/CodingGuidelines says\n\n - Fixing style violations while working on a real change as a\n   preparatory clean-up step is good, but otherwise avoid useless code\n   churn for the sake of conforming to the style.\n\n   \"Once it _is_ in the tree, it's not really worth the patch noise to\n   go and fix it up.\"\n   Cf. http://article.gmane.org/gmane.linux.kernel/943020\n\nwhich I think goes too far (some patterns really are error prone\nor distracting and it can be worth fixing them tree-wide), but it\nmakes a reasonable case that an idiom not being preferred in the\nstyle guide is not *on its own* enough reason to change it.\n\nPerhaps something like the following would work?\n\n\ttree-wide: convert test -a/-o to && and ||\n\n\tThe interaction with unary operators and operator precedence\n\tfor && and || are better known than -a and -o, and for that\n\treason we prefer them.  Replace all existing instances in git\n\tof -a and -o to save readers from the burden of thinking\n\tabout such things.\n\n\tAdd a check-non-portable-shell.pl to avoid more instances of\n\ttest -a and -o arising in the future.\n\n[...]\n> -\t\t\ttest $status = D -o $status = T && echo \"$sm_path\" && continue\n> +\t\t\t ( test $status = D || test $status = T ) && echo \"$sm_path\" && continue\n\nThere's no need for a subshell for this.  Better to use a block:\n\n\t\t\t{\n\t\t\t\ttest \"$status\" = D ||\n\t\t\t\ttest \"$status\" = T\n\t\t\t} &&\n\t\t\techo \"$sm_path\" &&\n\t\t\tcontinue\n\nor an if statement:\n\n\t\t\tif test \"$status\" = D || test \"$status\" = T\n\t\t\tthen\n\t\t\t\techo \"$sm_path\"\n\t\t\t\tcontinue\n\t\t\tfi\n\nor case:\n\n\t\t\tcase $status in\n\t\t\tD|T)\n\t\t\t\techo \"$sm_path\"\n\t\t\t\tcontinue\n\t\t\t\t;;\n\t\t\tesac\n\nHope that helps,\nJonathan\n"},{"id":"241859","messageId":"20140516082438.GA2673@gmail.com","threadId":"36665","inReplyTo":"1400163457-28285-8-git-send-email-gitter.spiros@gmail.com","subject":"Re: [PATCH 08/10] git-mergetool.sh: don't use the -a or -b option with the test command","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2014-05-16T08:24:39Z","receivedAt":"2014-05-16T08:24:39Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"On Thu, May 15, 2014 at 07:17:35AM -0700, Elia Pinto wrote:\n> Even though POSIX.1 lists -a/-o as options to \"test\", they are\n> marked \"Obsolescent XSI\". Scripts using these expressions\n> should be converted  as follow:\n> \n> test \"$1\" -a \"$2\"\n> \n> should be written as:\n> \n> test \"$1\" && test \"$2\"\n> \n> Likewise\n> \n> test \"$1\" -o \"$2\"\n> \n> should be written as:\n> \n> test \"$1\"  test \"$2\"\n> \n> But note that, in test, -a has higher precedence than -o while\n> \"&&\" and \"||\" have equal precedence in the shell.\n> \n> The reason for this is that the precedence rules were never well\n> specified, and this made many sane-looking uses of \"test -a/-o\" problematic.\n> \n> For example, if $x is \"=\", these work according to POSIX (it's not\n> portable, but in practice it's okay):\n> \n>    $ test -z \"$x\"\n>    $ test -z \"$x\" && test a = b\n> \n> but this doesn't\n> \n>    $ test -z \"$x\" -a a = b\n>    bash: test: too many arguments\n> \n> because it groups \"test -n = -a\" and is left with \"a = b\".\n> \n> Similarly, if $x is \"-f\", these\n> \n>    $ test \"$x\"\n>    $ test \"$x\" || test c = d\n> \n> correctly adds an implicit \"-n\", but this fails:\n> \n>    $ test \"$x\" -o c = d\n>    bash: test: too many arguments\n> \n> Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>\n> ---\n> Inspired from this discussion http://permalink.gmane.org/gmane.comp.version-control.git/137056\n\nLooks good, thanks.\n\nAcked-by: David Aguilar <davvid@gmail.com>\n\n\n>  git-mergetool.sh |    4 ++--\n>  1 file changed, 2 insertions(+), 2 deletions(-)\n> \n> diff --git a/git-mergetool.sh b/git-mergetool.sh\n> index 332528f..88e853f 100755\n> --- a/git-mergetool.sh\n> +++ b/git-mergetool.sh\n> @@ -205,7 +205,7 @@ checkout_staged_file () {\n>  \t\t\"$(git checkout-index --temp --stage=\"$1\" \"$2\" 2>/dev/null)\" \\\n>  \t\t: '\\([^\t]*\\)\t')\n>  \n> -\tif test $? -eq 0 -a -n \"$tmpfile\"\n> +\tif test $? -eq 0 && test -n \"$tmpfile\"\n>  \tthen\n>  \t\tmv -- \"$(git rev-parse --show-cdup)$tmpfile\" \"$3\"\n>  \telse\n> @@ -256,7 +256,7 @@ merge_file () {\n>  \tcheckout_staged_file 2 \"$MERGED\" \"$LOCAL\"\n>  \tcheckout_staged_file 3 \"$MERGED\" \"$REMOTE\"\n>  \n> -\tif test -z \"$local_mode\" -o -z \"$remote_mode\"\n> +\tif test -z \"$local_mode\" || test -z \"$remote_mode\"\n>  \tthen\n>  \t\techo \"Deleted merge conflict for '$MERGED':\"\n>  \t\tdescribe_file \"$local_mode\" \"local\" \"$LOCAL\"\n> -- \n> 1.7.10.4\n-- \nDavid\n"},{"id":"241995","messageId":"xmqq7g5la6c6.fsf@gitster.dls.corp.google.com","threadId":"36665","inReplyTo":"20140515155821.GA27279@google.com","subject":"Re: [PATCH 10/10] git-submodule.sh: don't use the -a or -b option with the test command","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2014-05-16T19:09:29Z","receivedAt":"2014-05-16T19:09:29Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n> Perhaps something like the following would work?\n>\n> \ttree-wide: convert test -a/-o to && and ||\n>\n> \tThe interaction with unary operators and operator precedence\n> \tfor && and || are better known than -a and -o, and for that\n> \treason we prefer them.  Replace all existing instances in git\n> \tof -a and -o to save readers from the burden of thinking\n> \tabout such things.\n>\n> \tAdd a check-non-portable-shell.pl to avoid more instances of\n> \ttest -a and -o arising in the future.\n\nYeah, the title is certainly better than \"-a or -b option\" I see\nabove ;-) and a single tree-wide fix may be OK while the tree is\nquiescent.\n\nI however do think \"better known\" is much less of an issue than that\n\"-a/-o\" is more error prone e.g. 'test -n \"$x\" -a a = b' is buggy\nbecause it does not consider that $x could be \"=\".\n\n\n\n> [...]\n>> -\t\t\ttest $status = D -o $status = T && echo \"$sm_path\" && continue\n>> +\t\t\t ( test $status = D || test $status = T ) && echo \"$sm_path\" && continue\n>\n> There's no need for a subshell for this.  Better to use a block:\n>\n> \t\t\t{\n> \t\t\t\ttest \"$status\" = D ||\n> \t\t\t\ttest \"$status\" = T\n> \t\t\t} &&\n> \t\t\techo \"$sm_path\" &&\n> \t\t\tcontinue\n\nYes.\n"}]}