1
0
Fork 0
mirror of https://github.com/SinTan1729/random.git synced 2024-12-25 20:58:37 -06:00

fix: Relative locations of scripts

This commit is contained in:
Sayantan Santra 2023-12-05 02:16:30 -06:00
parent 8dab2cac01
commit 50af9d5762
Signed by: SinTan1729
GPG key ID: EB3E68BFBA25C85F

View file

@ -19,9 +19,9 @@ elif [ "$3" == "fin" ]; then
cp -l "$item" ../Temp/ cp -l "$item" ../Temp/
cd ../Temp/ cd ../Temp/
old=$(ls) old=$(ls)
movie-rename -l * ../.config/movie-rename -l *
new=$(ls) new=$(ls)
folderify.py ../.config/folderify.py
[ "$old" != "$new" ] && mv * ../Movies/ [ "$old" != "$new" ] && mv * ../Movies/
fi fi
@ -30,11 +30,12 @@ elif [ "$3" == "fin" ]; then
cd ../Temp/ cd ../Temp/
cd * cd *
find . -name "*.srt" | tail -n 1 | xargs -I{} mv {} . find . -name "*.srt" | tail -n 1 | xargs -I{} mv {} .
rename-subs en ../.config/rename-subs en
find . -type d -exec rm -rf "{}" \; find . -type d -exec rm -rf "{}" \;
find . \! \( -name "*.mp4" -o -name "*.srt" -o -name "*.mkv" \) -exec rm -f "{}" \; find . \! \( -name "*.mp4" -o -name "*.srt" -o -name "*.mkv" \) -exec rm -f "{}" \;
old=$(ls) old=$(ls)
movie-rename -ld "$item" cd ..
../.config/movie-rename -ld "$item"
new=$(ls) new=$(ls)
[ "$old" != "$new" ] && mv * ../Movies/ [ "$old" != "$new" ] && mv * ../Movies/
fi fi