diff options
author | Denys Vlasenko | 2009-06-09 18:40:52 +0200 |
---|---|---|
committer | Denys Vlasenko | 2009-06-09 18:40:52 +0200 |
commit | 9d617c44d2b1135d14b7dafd01a1d3992293f4d9 (patch) | |
tree | a763d31365f18cb2bb984d252bc849f03c45625a /shell/hush_test/hush-bugs/export_exp.tests | |
parent | 2634bf366b298a827d043566656f8696f4dc153c (diff) | |
download | busybox-9d617c44d2b1135d14b7dafd01a1d3992293f4d9.zip busybox-9d617c44d2b1135d14b7dafd01a1d3992293f4d9.tar.gz |
hush: specially handle [[ - suppress globbing & multiword expansion
It's a bashism, but is surprisingly easy to do and costs very little code.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell/hush_test/hush-bugs/export_exp.tests')
-rwxr-xr-x | shell/hush_test/hush-bugs/export_exp.tests | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/shell/hush_test/hush-bugs/export_exp.tests b/shell/hush_test/hush-bugs/export_exp.tests new file mode 100755 index 0000000..91f57aa --- /dev/null +++ b/shell/hush_test/hush-bugs/export_exp.tests @@ -0,0 +1,19 @@ +v="a=aa0 b=bb0" +# only 1st arg should be expanded in multiple words +export $v c=$v +echo $a $b +echo $c + +# only 1st arg should be expanded in multiple words +export `echo a=aa1 b=bb1` c=`echo a=aa1 b=bb1` +echo $a $b +echo $c + +>zz=zz +>zzz=zzz +# only 1st arg should be globbed +export zzz* zz=* +env | grep ^zz | sort +rm -rf zz=zz zzz=zzz + +echo Done |