[PATCH] Shell programming: directories are ``executable'' (that is, searchable), too.

Michal Sojka sojkam1 at fel.cvut.cz
Sat Feb 5 14:59:15 PST 2011


On Wed, 02 Feb 2011, Thomas Schwinge wrote:
> Signed-off-by: Thomas Schwinge <thomas at 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

Looks good to me. Thanks.

-Michal


More information about the notmuch mailing list