Change script to work with new file structure
File structure: MusikRaw > Artist > Albums > {normalized, transcode}
This commit is contained in:
parent
1ef4211ce9
commit
a75b240ba1
@ -5,12 +5,23 @@ set -euo pipefail
|
|||||||
cd "$HOME/MusikRaw"
|
cd "$HOME/MusikRaw"
|
||||||
|
|
||||||
# get directories
|
# get directories
|
||||||
ls -d */ > directories
|
ls -d */ > artistdirectories
|
||||||
|
|
||||||
while read -r dir; do
|
while read -r artdir; do
|
||||||
cd "$dir"
|
cd "$artdir"
|
||||||
rm -rf normalized
|
# get albums
|
||||||
|
ls -d */ > directories
|
||||||
|
# delete normalized from albums
|
||||||
|
while read -r dir; do
|
||||||
|
cd "$dir"
|
||||||
|
rm -rf normalized
|
||||||
|
cd "$HOME/MusikRaw/$artdir"
|
||||||
|
done < directories
|
||||||
|
# cleanup
|
||||||
|
rm directories
|
||||||
cd "$HOME/MusikRaw"
|
cd "$HOME/MusikRaw"
|
||||||
done < directories
|
done < artistdirectories
|
||||||
|
# cleanup
|
||||||
|
rm artistdirectories
|
||||||
|
|
||||||
exit
|
exit
|
||||||
|
@ -5,12 +5,23 @@ set -euo pipefail
|
|||||||
cd "$HOME/MusikRaw"
|
cd "$HOME/MusikRaw"
|
||||||
|
|
||||||
# get directories
|
# get directories
|
||||||
ls -d */ > directories
|
ls -d */ > artistdirectories
|
||||||
|
|
||||||
while read -r dir; do
|
while read -r artdir; do
|
||||||
cd "$dir"
|
cd "$artdir"
|
||||||
rm -rf "transcode"
|
# get albums
|
||||||
|
ls -d */ > directories
|
||||||
|
# delete normalized from albums
|
||||||
|
while read -r dir; do
|
||||||
|
cd "$dir"
|
||||||
|
rm -rf "transcode"
|
||||||
|
cd "$HOME/MusikRaw/$artdir"
|
||||||
|
done < directories
|
||||||
|
# cleanup
|
||||||
|
rm directories
|
||||||
cd "$HOME/MusikRaw"
|
cd "$HOME/MusikRaw"
|
||||||
done < directories
|
done < artistdirectories
|
||||||
|
# cleanup
|
||||||
|
rm artistdirectories
|
||||||
|
|
||||||
exit
|
exit
|
||||||
|
Loading…
Reference in New Issue
Block a user