When on linux split -d can be used as a numeric suffixes starting at 0, so like having
split -d -l 1500 ${TEMP_FILE} ${OUTPUT_FILE}
mv "${DATADIR}/${DATASET}/user_artists00" "${DATADIR}/${DATASET}/user_artists.train"
mv "${DATADIR}/${DATASET}/user_artists01" "${DATADIR}/${DATASET}/user_artists.test"
but on macOS the -d option it is missing. According to man we have
-a suffix_length
Use suffix_length letters to form the suffix of the file name.
and it is stated
If additional arguments are specified, the first is used as the name of the input file which is to be split. If a second additional argument is speci- fied, it is used as a prefix for the names of the files into which the file is split. In this case, each file into which the file is split is named by the prefix followed by a lexically ordered suffix using suffix_length characters in the range ``a-z''. If -a is not specified, two letters are used as the suffix.
so in my understanding I cannot have as output file something like $MYINPUT00, $MYINPUT01, etc, while only xaa, xab, etc. by defaults, since -a only admits a [a-z] range.
You can install brew install coreutils with Homebrew and invoke the GNU split gsplit instead to use the -d argument.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With