cli: change argument parsing convention for subcommands
authorDavid Bremner <bremner@debian.org>
Fri, 21 Oct 2011 12:19:17 +0000 (09:19 -0300)
committerDavid Bremner <bremner@debian.org>
Sat, 22 Oct 2011 22:42:54 +0000 (19:42 -0300)
commit61f0a5b8ee2adf540106a09c5f83fe634da6beb3
tree07ca532a91a0fb47b3079ec3937ff1a18ad3cd79
parent8bb5b6201ec2cb890655fee6ef7e540f401a4c7e
cli: change argument parsing convention for subcommands

previously we deleted the subcommand name from argv before passing to
the subcommand. In this version, the deletion is done in the actual
subcommands. Although this causes some duplication of code, it allows
us to be more flexible about how we parse command line arguments in
the subcommand, including possibly using off-the-shelf routines like
getopt_long that expect the name of the command in argv[0].
notmuch-config.c
notmuch-count.c
notmuch-dump.c
notmuch-new.c
notmuch-reply.c
notmuch-restore.c
notmuch-search.c
notmuch-show.c
notmuch-tag.c
notmuch.c