Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread NGie Cooper
On Mon, Dec 7, 2015 at 11:17 AM, Ian Lepore wrote: ... > Arrr! No no no no, a thousand times NO. > > There is NO EXCUSE for that ugly unnecessary xfoo stuff. Quoting > properly supplies all the bulletproofing needed for string comparisons. The xfoo stuff protected against... foo="-lt t

Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Ian Lepore
On Mon, 2015-12-07 at 11:07 -0800, Garrett Cooper wrote: > > On Dec 7, 2015, at 10:13, Ian Lepore wrote: > > > > > On Mon, 2015-12-07 at 10:24 +, Warner Losh wrote: > > > Author: imp > > > Date: Mon Dec 7 10:24:38 2015 > > > New Revision: 291929 > > > URL: https://svnweb.freebsd.org/changese

Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Ed Maste
On 7 December 2015 at 14:07, Garrett Cooper wrote: > > Warner's commit was good. There's a more bulletproof way to do this to make > it more portable (in most cases, not all), but it would be overkill: > > [ "x$x" != x ] That construct is to support ancient shells that haven't been relevant for

Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Garrett Cooper
> On Dec 7, 2015, at 10:13, Ian Lepore wrote: > >> On Mon, 2015-12-07 at 10:24 +, Warner Losh wrote: >> Author: imp >> Date: Mon Dec 7 10:24:38 2015 >> New Revision: 291929 >> URL: https://svnweb.freebsd.org/changeset/base/291929 >> >> Log: >> Make sure to quote the arg after -n and -z te

Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Ed Maste
On 7 December 2015 at 13:13, Ian Lepore wrote: > > While I am generally a quoting fanatic and would much rather overquote > than underquote in shell scripts, fyi it's not actually needed for the > -n and -z tests. test(1) and shells seem to be smart enough to see the > ']' (which is just an arg t

Re: svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Ian Lepore
On Mon, 2015-12-07 at 10:24 +, Warner Losh wrote: > Author: imp > Date: Mon Dec 7 10:24:38 2015 > New Revision: 291929 > URL: https://svnweb.freebsd.org/changeset/base/291929 > > Log: > Make sure to quote the arg after -n and -z tests. > While I am generally a quoting fanatic and would mu

svn commit: r291929 - head/tools/tools/nanobsd

2015-12-07 Thread Warner Losh
Author: imp Date: Mon Dec 7 10:24:38 2015 New Revision: 291929 URL: https://svnweb.freebsd.org/changeset/base/291929 Log: Make sure to quote the arg after -n and -z tests. Modified: head/tools/tools/nanobsd/defaults.sh (contents, props changed) Modified: head/tools/tools/nanobsd/defaults.