]> git.tuebingen.mpg.de Git - gsu.git/commit - subcommand
subcommand: Overhaul _gsu_print_available_commands().
authorAndre Noll <maan@tuebingen.mpg.de>
Sat, 30 Aug 2014 16:47:50 +0000 (18:47 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Sat, 30 Aug 2014 16:47:50 +0000 (18:47 +0200)
commit96dedb2c454e93e307a45721b202f304c9464a2b
tree51780d5df7c758deada84029a74aa852a6b93ae1
parentf31cc416b1acdbb8f5703b208d943ce500a5b840
subcommand: Overhaul _gsu_print_available_commands().

This function is rather confused. It uses gsu_short_msg() to print
the header to stderr while the list of subcommands is printed to
stdout. This is "fixed" by executing all commands in a subshell and
redirecting stderr to stdout.

It's easier to just print everything to stdout. This patch also
renames the loop variable i to cmd, declares $count as a local
integer variable and switches to single quoted string constants.
subcommand