injekt/slop — pull request #97 by kyrylo (2012-12-23 11:46:26+00:00)
Title: Don't always append global/default headers

```ruby
commands = Slop::Commands.new do
default do
end

global do
end

on 'version'
end

p commands.to_s
#=> " Global options\n\n\n Other options\n"
```

Invokations of `global` or `default` methods with bare blocks (that is,
without option declarations) appends to the `helps` local variable
unwanted information, which results in this:

% my_cli_app --help
Global options

Other options
%

Fix it by checking whether global or default options, actually, have any
options defined.