Giuseppe Scrivano wrote: > --page-increment seems the wrong name for this option, --line-increment > is clearer. what do you think of this change?
Good catch. Thanks for the patch. I wonder if anyone has ever used that option ;-) ... > diff --git a/NEWS b/NEWS ... > +** Deprecated options > + > + nl --page-increment: deprecated in favour of --line-increment, the new > option > + maintains the previous semantic and the same short option, -i. s/semantic/semantics/ ... > diff --git a/src/nl.c b/src/nl.c > index 2deb314..ea7ebe6 100644 > --- a/src/nl.c > +++ b/src/nl.c > @@ -150,7 +150,9 @@ static struct option const longopts[] = > {"body-numbering", required_argument, NULL, 'b'}, > {"footer-numbering", required_argument, NULL, 'f'}, > {"starting-line-number", required_argument, NULL, 'v'}, > - {"page-increment", required_argument, NULL, 'i'}, > + {"line-increment", required_argument, NULL, 'i'}, > + /* FIXME: page-increment is deprecated, remove in dec-2011. */ > + {"page-increment", required_argument, NULL, 'I'}, Please don't use "I". Use something like PAGE_INCREMENT_OPTION_DEPRECATED, as is done in install.c for PRESERVE_CONTEXT_OPTION_DEPRECATED. I.e., define this, enum { PAGE_INCREMENT_OPTION_DEPRECATED = CHAR_MAX + 1, }; Then handle it in the same way install.c handles its deprecated long option: case PRESERVE_CONTEXT_OPTION_DEPRECATED: error (0, 0, _("WARNING: --preserve_context is deprecated; " "use --preserve-context instead")); /* fall through */ case PRESERVE_CONTEXT_OPTION: ...