Assistance with 'split -l' command
René Berber
rene.berber@gmail.com
Wed Aug 12 01:32:22 GMT 2020
On 8/11/2020 6:57 PM, Gary Vaughan via Cygwin wrote:
> I am working with csv files and when I perform the split -l, it
> splits the fioe correctly, but is putting the 'aa','ab','ac' after
> the file extension. Would love to know how to get it after the file
> name before the file extension. as an exampole, command split -l 5000
> /desktop/ESM.csv /desktop/ESM.csv is resulting ESM/csvaa and would
> like it to be ESMaa.csv
`man split` is your friend.
Try: split -l 5000 --additional-suffix=.csv /desktop/ESM.csv
/desktop/ESM.csv ESM
(all in one line)
It means split ... with resulting prefix "ESM", and suffix ".csv").
The command you show has default prefix x, no sufix, then the result
should have been xaa, xab, xac, etc.
--
R. Berber
More information about the Cygwin
mailing list