News for hackers. Stuff that matters.
Re:Shell programming with bash: by example, by counter-example by unhammer on Friday January 17, 2014 @02:50AM (#7074763)
http://mywiki.wooledge.org/BashFAQ/031 is a great reference.

If your guide is for bash and not sh, then I would say don't teach them [, just do [[. It's safer, since it won't glob or split words, you don't need quoting, and you don't need to escape operators like < and >. Maybe it's can be seen as more difficult since it's a sublanguage (doesn't use the regular syntax rules), but so are (( and $(( which you've discussed at length, and which are typically less useful than [[ in bash.

There are no comments on this comment yet.