swcarpentry/bc — pull request #633 by jensv (2014-07-28 22:41:53+00:00)
Title: Fix shell 05-script goostats option error

I added option handling to `goostats` with `getopts`.

`goostats` as added in #254 is returning an error when used with the options `-J 100 -r` as described in lesson 5. `-J` was being passed to head which returned invalid option. To fix this I added option handling with `getopts`. I assume the contents of `goostats` will not usually be looked at in a bootcamp. Coincidentally at 2014-07-28-stanford a student asked how to handle options. So it came in handy as an example :)