From: Thomas Schwinge <thomas@schwinge.name>
To: notmuch@notmuchmail.org
Cc: Thomas Schwinge <thomas@schwinge.name>
Subject: [PATCH] Shell programming: directories are ``executable'' (that is, searchable), too.
Date: Wed, 2 Feb 2011 19:17:09 +0100 [thread overview]
Message-ID: <1296670629-27711-1-git-send-email-thomas@schwinge.name> (raw)
Signed-off-by: Thomas Schwinge <thomas@schwinge.name>
---
test/test-lib.sh | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/test/test-lib.sh b/test/test-lib.sh
index f536172..3471ead 100755
--- a/test/test-lib.sh
+++ b/test/test-lib.sh
@@ -815,13 +815,14 @@ EOF
}
+# Locate the directory containing the `notmuch' executable we are to use.
find_notmuch_path ()
{
dir="$1"
while [ -n "$dir" ]; do
bin="$dir/notmuch"
- if [ -x "$bin" ]; then
+ if [ -f "$bin" -a -x "$bin" ]; then
echo "$dir"
return
fi
@@ -858,7 +859,7 @@ then
make_valgrind_symlink () {
# handle only executables
- test -x "$1" || return
+ test -f "$1" -a -x "$1" || return
base=$(basename "$1")
symlink_target=$TEST_DIRECTORY/../$base
--
1.7.1
next reply other threads:[~2011-02-02 18:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-02 18:17 Thomas Schwinge [this message]
2011-02-05 22:59 ` [PATCH] Shell programming: directories are ``executable'' (that is, searchable), too Michal Sojka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1296670629-27711-1-git-send-email-thomas@schwinge.name \
--to=thomas@schwinge.name \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).