tired of manually updating my huge mp3/mp4 DB each time i add new files on my computer and/or smartphone, so i'm looking for some help to create a batch file that create/update all my playlists .m3u automatically.
2 batch files are required (1st is calling the 2nd) :
1st one is easy, i've almost got it ;-)
create_all_playlist.bat (no arguments required, customized file)
create_m3u.bat misc-70-80.m3u misc\70\ misc\80\
create_m3u.bat misc-70-80-90.m3u misc\70\ misc\80\ misc\90\
create_m3u.bat misc-60-70-2000-2010.m3u misc\60\ misc\70\ misc\2000\ misc\2010\
[...]
create_m3u.bat albums-2010.m3u albums\2010\
pretty easy huh?
I need your help to write the 2nd .bat, the dynamic one :
create_m3u.bat output-playlist-name.m3u folder-1 folder-2 [...] folder-n
to play it easy, the output file.m3u should looks like this (note all are relative path and the search for *.mp3 *.mp4 *.ogg (whatever type i cutomize/hard-code) would be recursive into the designated folder)
(raw .m3u compatible with most android & PC player)
misc\2000s\Kelly Rowland - Work (Freemasons Arabic Mix).mp3
misc\2000s\Keri Hilson - Knock You Down ft Kanye West and Ne-Yo.mp3
misc\2000s\Kid Cudi vs Crookers - Day n Nite.mp3
misc\2000s\Korn - Inja.mp3
[...]
misc\2000s\Ladyhawke - My Delirium.mp3
At very best, only for the very best, let's say if someone is skilled enough to produce the full mp3/mp4 TAG reading and formating as following
#EXTM3U
#EXTINF:227,A-Ha - Take On Me
misc\80s\A-Ha - Take On Me.mp3
#EXTINF:257,ACDC - Back in Black
misc\80s\ACDC - Back in Black.mp3
#EXTINF:311,Aerosmith & Run Dmc - Walk This Way
misc\80s\Aerosmith & Run Dmc - Walk This Way.mp3
[...]
#EXTINF:289,Alannah Myles - Black Velvet
misc\80s\Alannah Myles - Black Velvet.mp3
and thanks!!
for the raw m3u, beers are on me :-)
for the extended full m3u : beers and i'll cook the duck magret ;-)
I used
c:\sourcedir
as my starting directory. No parameter-validity checks are performed. You'd need toCALL create_m3u.bat
fromcreate_all_playlist.bat
because the target executble is a batch file.As for the missing data - hardest part is extracting information....
Edited to allow
!
in filenames and remove leading\
from pathRevision: To permit absolute path
Noting that "paths containing spaces must be in quotes"