mirror of
https://github.com/SinTan1729/random.git
synced 2025-04-11 13:46:04 -05:00
fix: Ignore subdirectories in folderify
This commit is contained in:
parent
d84cd484d9
commit
e422459f6c
1 changed files with 2 additions and 2 deletions
|
@ -14,14 +14,14 @@ process_file () {
|
||||||
else
|
else
|
||||||
mkdir "$without_ext"
|
mkdir "$without_ext"
|
||||||
mv "$filename" "$without_ext/"
|
mv "$filename" "$without_ext/"
|
||||||
find . -type f -regextype posix-egrep -iregex "\./$without_ext(\.[a-z]{2,3})?\.srt" \
|
find . -maxdepth 1 -type f -regextype posix-egrep -iregex "\./$without_ext(\.[a-z]{2,3})?\.srt" \
|
||||||
-exec mv "{}" "$without_ext/" \;
|
-exec mv "{}" "$without_ext/" \;
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
counter=0
|
counter=0
|
||||||
|
|
||||||
find . -type f -regextype posix-egrep -iregex '.*\.(mkv|mp4)$' -print0 | while IFS= read -r -d '' file; do
|
find . -maxdepth 1 -type f -regextype posix-egrep -iregex '.*\.(mkv|mp4)$' -print0 | while IFS= read -r -d '' file; do
|
||||||
process_file
|
process_file
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue