split: support optional start value for --numeric-suffixes
authorJérémy Compostella <jeremy.compostella@gmail.com>
Sun, 29 Jan 2012 14:20:31 +0000 (15:20 +0100)
committerPádraig Brady <P@draigBrady.com>
Sat, 18 Feb 2012 02:09:32 +0000 (02:09 +0000)
commitd55d3dd5886c146547482c9f45ac653c1ebe9237
tree165a83aa229b68e3c29fb292b998e9389624a452
parent557b3b2a359b8d6ed59dd9b61f34043b40f9e036
split: support optional start value for --numeric-suffixes

Allow changing the --numeric-suffixes start number
from the default of 0.

* src/split.c (next_file_name): Initialize the suffix index
and the output filename according to start value.
(main): Check that the suffix length is large enough for the
numerical suffix start value.
* doc/coreutils.texi (split invocation): Mention it.
* NEWS (New features): Mention it.
* tests/split/numeric: New file. Test --numeric-suffixes[=FROM].
* tests/Makefile.am (TESTS): Reference the new test.
NEWS
doc/coreutils.texi
src/split.c
tests/Makefile.am
tests/split/numeric [new file with mode: 0755]