Comment by sieve

4 years ago

> inserting quoting where it's needed

You have to remind yourself to do this manually in scripts if you don't want to see lines full of "No such file or directory."

One of the reasons the shell is broken is because the character they use as an argument array member separator is something that regular people use to distinguish between two words, such as in a file name.

Well, writing scripts would be much less painful if $VARNAME did not explode into pieces by default. Alas, this ship has sailed long ago.

  • IMHO, it's possible to add a flag to bash, which will turn on this behavior, so problem can be fixed, but it will diverge bash from POSIX sh a lot.