aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorneodarz <neodarz@neodarz.net>2019-07-07 13:43:35 +0200
committerneodarz <neodarz@neodarz.net>2019-07-07 13:43:35 +0200
commit3efa1507cb86faeab7fba0a630793b2117059545 (patch)
treefa1b9f314e6529f84273c6bd6f15dbe2a05133fb
parent2efd74df4afb1127ef7d4289c7e5a1386318699e (diff)
downloadconvert.py-master.tar.xz
convert.py-master.zip
Add mod and xm file supportHEADmaster
-rw-r--r--README.md2
-rwxr-xr-xconvert.py4
2 files changed, 3 insertions, 3 deletions
diff --git a/README.md b/README.md
index 7151544..b76675d 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# convert.py
-This tool can convert files from mp4, mkv or webw to mp3.
+This tool can convert files from mp4, mkv, webw, mod or xm to mp3.
It use ffmpeg for the conversion.
diff --git a/convert.py b/convert.py
index f8bd56c..2782954 100755
--- a/convert.py
+++ b/convert.py
@@ -27,7 +27,7 @@ if len(sys.argv) >= 3 and len(sys.argv) <= 4:
print("No such file or directory: '"+str(sourcedir)+"'")
sys.exit()
else:
- print("Simple tool for convert mp4, mkv or webm file to mp3")
+ print("Simple tool for convert mp4, mkv, webm, mod or xm file to mp3")
print("Usage:\nconvert.py [-n|-y] [SOURCE] [DESTINATION]")
print(" -n ffmpeg: Doesn't overwrite output files, and go to next file to be converted if the specified output file already exists. (Default option)")
print(" -y ffmpeg: Overwrite output files.")
@@ -53,7 +53,7 @@ count = 0
for file in sorted(os.listdir(sourcedir)):
try:
name = file[:file.rfind(".")]
- ext = [".mp4", ".mkv", ".webm"]
+ ext = [".mp4", ".mkv", ".webm", ".mod", ".xm"]
if file.endswith(tuple(ext)):
exist = False
if os.path.isfile(outdir+"/"+name+".mp3") and arg == "-n":