Subject: bug#28228: split issue?

From: Xikai Jiang <[email-masked]>
Date: Fri, 25 Aug 2017 15:23:26 +0000

Hi Assaf:

Ok, I see. I'll use -a5 for large number of splitted files then.

Thanks for your explanations.

Regards, Xikai

________________________________________
From: Assaf Gordon [[email-masked]]
Sent: Thursday, August 24, 2017 4:59 PM
To: Xikai Jiang; [email-masked]
Subject: Re: bug#28228: split issue?

tag 28228 notabug
close 28228
thanks

Hello,

On 24/08/17 02:02 PM, Xikai Jiang wrote:
> When I use 'split -d -l 3 my.file' to split a file, there seems to be a discontinuity in the numeric suffixes of the resulting files (x89 to x9000, see the attached image.)
>
> Could you help on this issue?

behavior is by design.
Please read about it here:
  https://www.pixelbeat.org/docs/coreutils-gotchas.html#split

The reasoning is:
"It's done like that so there is no limit to the number of output files,
but also that those output files sort correctly with a lexical sort.
If you want consecutive numbers then specify enough digits with -a5 etc."
(from: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20874).

As such I'm closing this bug report, but discussion can continue
by replying to this thread.

regards,
 - assaf