Set of minor fixes (#11)

* minor fix on main script

* added gitignore

* Fixed problem related to sudo misused on the convert command
This commit is contained in:
Vincenzo "vikkio88
2016-10-11 16:15:19 +01:00
committed by Ritiek Malhotra
parent aac2020214
commit f740b17cf0
2 changed files with 3 additions and 2 deletions

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
Music/

View File

@@ -35,7 +35,7 @@ def Main():
os.remove('Music/' + m)
print('')
print('')
raw_song = raw_input('>> Enter a song/cmd: ').encode(utf-8)
raw_song = raw_input('>> Enter a song/cmd: ').encode('utf-8')
print ''
if raw_song == "exit":
exit()
@@ -229,7 +229,7 @@ def Main():
print ''
print 'Converting ' + Title + '.m4a' + ' to mp3..'
if not os.name == 'nt':
os.system('sudo avconv -loglevel 0 -i "' + script_dir + 'Music/' + Title + '.m4a" -ab 192k "' + script_dir + 'Music/' + Title + '.mp3"')
os.system('avconv -loglevel 0 -i "' + script_dir + 'Music/' + Title + '.m4a" -ab 192k "' + script_dir + 'Music/' + Title + '.mp3"')
else:
os.system('Scripts\\avconv.exe -loglevel 0 -i "' + script_dir + 'Music/' + Title + '.m4a" -ab 192k "' + script_dir + 'Music/' + Title + '.mp3"')
os.remove('Music/' + Title + '.m4a')