From 9760ee23c79818e7d94c11b895e9f923335cc58f Mon Sep 17 00:00:00 2001 From: Ingo Karkat Date: Thu, 21 Oct 2010 12:27:30 +0200 Subject: [PATCH] Avoiding todo.sh help error when .todo.actions.d contains subdirs. I have placed tests for my custom todo actions in ~/.todo.actions.d/tests/; this causes a ".../.todo.actions.d/tests: is a directory" error on todo.sh help. Added condition for regular files to the executable check in order to exclude subdirectories. --- todo.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/todo.sh b/todo.sh index 99320c9..4d0fb15 100755 --- a/todo.sh +++ b/todo.sh @@ -232,7 +232,7 @@ help() echo "" for action in "$TODO_ACTIONS_DIR"/* do - if [ -x "$action" ] + if [ -f "$action" -a -x "$action" ] then "$action" usage fi