make sure sorting is ok

This commit is contained in:
Ville Rantanen
2021-01-29 14:08:42 +02:00
parent 5accdec9e2
commit 24945af179

View File

@@ -28,7 +28,7 @@ done
printf -v padstr "%%0%dd" $pad printf -v padstr "%%0%dd" $pad
_drive() { _drive() {
ls -1prt | grep -v "/$" | cat -n | while read n f; do ls -1p | grep -v "/$" | sort -V | cat -n | while read n f; do
printf -v padded $padstr $n printf -v padded $padstr $n
if [[ $keep = true ]]; then if [[ $keep = true ]]; then
printf -v outname "%s.%s" "$padded" "$f" printf -v outname "%s.%s" "$padded" "$f"