Re:Safe ways to do things in bash
by gmjosack on Monday May 14, 2018 @05:46PM
(#17069727)
Both of those examples end up being fine. When quoted the entire variable is passed as a single WORD and the shell won't interpret the `;` as the end of the command. Even without quoting the variable it would be fine in this case because of where you've put the quotes, though you should still quote the variables. As a simple illustration take a look at the following:
[ Parent
| on HN ]
There are no comments on this comment yet.