Otherwise the [[ EXPR ]] construct will not run. "hush: can't execute '[[': No such file or directory"
It seems like this thing has not been working from the beginning :( (commit 9d617c44d2b1135d14b7dafd01a1d3992293f4d9) Signed-off-by: Kang-Che Sung <[email protected]> --- shell/hush.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/shell/hush.c b/shell/hush.c index ecef099ac..68b838378 100644 --- a/shell/hush.c +++ b/shell/hush.c @@ -1073,6 +1073,9 @@ static const struct built_in_command bltins1[] = { static const struct built_in_command bltins2[] = { #if ENABLE_HUSH_TEST BLTIN("[" , builtin_test , NULL), +# if ENABLE_HUSH_BASH_COMPAT + BLTIN("[[" , builtin_test , NULL), +# endif #endif #if ENABLE_HUSH_ECHO BLTIN("echo" , builtin_echo , NULL), -- 2.11.0
From d041fce007fdf0c4072de213d8fcc1d621469469 Mon Sep 17 00:00:00 2001 From: Kang-Che Sung <[email protected]> Date: Wed, 11 Jan 2017 02:37:35 +0800 Subject: [PATCH 1/2] hush: add [[ to the builtins list Otherwise the [[ EXPR ]] construct will not run. "hush: can't execute '[[': No such file or directory" It seems like this thing has not been working from the beginning :( (commit 9d617c44d2b1135d14b7dafd01a1d3992293f4d9) Signed-off-by: Kang-Che Sung <[email protected]> --- shell/hush.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/shell/hush.c b/shell/hush.c index ecef099ac..68b838378 100644 --- a/shell/hush.c +++ b/shell/hush.c @@ -1073,6 +1073,9 @@ static const struct built_in_command bltins1[] = { static const struct built_in_command bltins2[] = { #if ENABLE_HUSH_TEST BLTIN("[" , builtin_test , NULL), +# if ENABLE_HUSH_BASH_COMPAT + BLTIN("[[" , builtin_test , NULL), +# endif #endif #if ENABLE_HUSH_ECHO BLTIN("echo" , builtin_echo , NULL), -- 2.11.0
_______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
