MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/commandline/comments/1luibp/utilshell_make_your_shell_script_actually_readable/cc2xceq/?context=3
r/commandline • u/taylorchu • Sep 06 '13
23 comments sorted by
View all comments
2
It's written in go so I can't figure out by myself but it seems your arrays aren't compatible with bash
arr=$(array new 1 2 3 4) array len "$arr"
that isn't an array, your array command writes something to stdout that you store as a plain variable.
array
-4 u/taylorchu Sep 06 '13 part of the design.that provides a way to export/import a variable.only string can be passed to a function 4 u/Samus_ Sep 06 '13 It's obvious that it's by design but that incompatibility is a big deal, it means to rewrite all scripts one may already have and also prevents interoperability with other scripts.
-4
part of the design.
that provides a way to export/import a variable.
only string can be passed to a function
4 u/Samus_ Sep 06 '13 It's obvious that it's by design but that incompatibility is a big deal, it means to rewrite all scripts one may already have and also prevents interoperability with other scripts.
4
It's obvious that it's by design but that incompatibility is a big deal, it means to rewrite all scripts one may already have and also prevents interoperability with other scripts.
2
u/Samus_ Sep 06 '13
It's written in go so I can't figure out by myself but it seems your arrays aren't compatible with bash
that isn't an array, your
arraycommand writes something to stdout that you store as a plain variable.