Page 1 of 1

export files from playlist to directory

Posted: 03 Oct 2013 20:38
by gurleen321
I know a lot of people wouldn't use this feature but it would be easy for picky people like me who select certain songs from certain album,s then have to export their favorites to another location like a flash drive or a cellphone so it would be awesome is vlc could make a copy of the files in the playlist to a specified directory and if this already exists please forgive me for being retarded :D also sorry for my english :)

Re: export files from playlist to directory

Posted: 10 Jan 2014 01:23
by davidmbusto
Hello there, well, what you might do is using the winamp plugin "send " to" for such a thing. But I have a student who uses vlc and as winamp is no longer on the run I got to this marvelous piece of german soft. I have no idea how to activate it, but IT IS TRANSLATED TO ENGLISH. http://www.amok.am/en/freeware/amok_playlist_copy/
Greetings from Argentina, Bahía Blanca.

Re: export files from playlist to directory

Posted: 10 Jan 2014 13:49
by mederi
Java application AudioM: http://sourceforge.net/projects/audiom/
Perhaps it is possible to write a batch/bash script to read/parse m3u playlist file and copy files to a desired destination.
And perhaps it is also possible to write a VLC Extension Lua script to copy files from actual VLC playlist to a desired destination.

--- EDIT (18.1.2014) ---
An example of batch script for copying files from "playlist.m3u" file to a destination directory "d:\dir\"

Code: Select all

@ECHO OFF REM CHCP 1250 FOR /f "tokens=*" %%a IN (playlist.m3u) DO ( ECHO %%~a COPY "%%~a" "d:\dir\%%~nxa" ) PAUSE
--- EDIT 9.9.2015 ---
added "tokens=*" option in FOR command

Re: export files from playlist to directory

Posted: 25 Jan 2014 09:16
by gurleen321
thanks guys will try both things mentions see what happens

Re: export files from playlist to directory

Posted: 23 May 2017 08:33
by Firbydude
Python script to copy the files from a m3u playlist to another directory (ex. python pl-copy.py pl.m3u path/to/output/dir/)
Gist: https://gist.github.com/Firbydude/8bf7e ... 60a625c3ed

Code: Select all

import sys import os from shutil import copyfile # python pl-copy.py all.m3u E:\music\ def main(): if len(sys.argv) < 3: return 1 playlist_file = sys.argv[1] output_dir = sys.argv[2] with open(playlist_file, 'r') as f: for line in f: if line.startswith('#'): # Skip m3u comments continue else: nle = line.rstrip() basename = os.path.basename(nle) print("copying file %s..." % (basename,)) dst = os.path.join(output_dir, basename) copyfile(nle, dst) return 0 if __name__ == "__main__": sys.exit(main())