FireFly Media Server › Firefly Media Server Forums › Firefly Media Server › General Discussion › Script for creating my playlist? › Reply To: Script for creating my playlist?
19/12/2006 at 4:10 AM
#8033
rpedde
Participant
@krolben wrote:
The structure of my music folders is:
/home/music/band name/album name/music fileThe naming convention I’d like to have in the playlist is:
“band name – album title” {
paths to songs
}
Not much of a shell scripter myself, but something like this ought to work:
#!/bin/sh
for artist in *; do
if [ -d "$artist" ]; then
pushd "$artist"
for album in *; do
find "$album" -name '*.mp3' -o -name '*.m4a' > "$artist - $album.m3u"
done;
popd
fi;
done;
That should make .m3u files for each album, or so I reckon.