Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElia Pinto <gitter.spiros@gmail.com>2014-06-06 18:55:44 +0400
committerJunio C Hamano <gitster@pobox.com>2014-06-10 01:47:06 +0400
commit4eaeb3264e1f86b99ba7732d9f69039a5805c435 (patch)
tree423b73f291199308196a3c3b943cb923240b0900 /check_bindir
parent0953113bb5687f42bcdfc3d20dd3a125784ad383 (diff)
check_bindir: avoid "test <cond> -a/-o <cond>"
The construct is error-prone; "test" being built-in in most modern shells, the reason to avoid "test <cond> && test <cond>" spawning one extra process by using a single "test <cond> -a <cond>" no longer exists. Signed-off-by: Elia Pinto <gitter.spiros@gmail.com> Reviewed-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'check_bindir')
-rwxr-xr-xcheck_bindir2
1 files changed, 1 insertions, 1 deletions
diff --git a/check_bindir b/check_bindir
index a1c4c3e8d8..623eadcbb7 100755
--- a/check_bindir
+++ b/check_bindir
@@ -2,7 +2,7 @@
bindir="$1"
gitexecdir="$2"
gitcmd="$3"
-if test "$bindir" != "$gitexecdir" -a -x "$gitcmd"
+if test "$bindir" != "$gitexecdir" && test -x "$gitcmd"
then
echo
echo "!! You have installed git-* commands to new gitexecdir."