]> git.ipfire.org Git - thirdparty/git.git/commit - parse-options.h
parseopt: add OPT_NOOP_NOARG
authorRené Scharfe <rene.scharfe@lsrfire.ath.cx>
Wed, 28 Sep 2011 17:44:30 +0000 (19:44 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 28 Sep 2011 19:46:21 +0000 (12:46 -0700)
commit6acec0380bfcd5e3f91c9100bf4d415db8f7acfd
tree16f376495294910ce5ab5b52415a4e8a774d5936
parentf858c646b5428519c4f847c5f15a9ead72a62b16
parseopt: add OPT_NOOP_NOARG

Add OPT_NOOP_NOARG, a helper macro to define deprecated options in a
standard way.  The help text is taken from the no-op option -r of
git revert.

The callback could be made to emit a (conditional?) warning later.  And
we could also add OPT_NOOP (requiring an argument) etc. as needed.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/technical/api-parse-options.txt
parse-options-cb.c
parse-options.h
t/t0040-parse-options.sh
test-parse-options.c