mirror of
https://github.com/KevinMidboe/spotify-downloader.git
synced 2025-12-08 20:39:08 +00:00
Add information about environment variables in Windows (#69)
This commit is contained in:
@@ -64,6 +64,10 @@ Shift+right-click on empty area and open cmd and type:
|
|||||||
|
|
||||||
`"Scripts/pip.exe" install -U -r requirements.txt`
|
`"Scripts/pip.exe" install -U -r requirements.txt`
|
||||||
|
|
||||||
|
- If you do not want to naviagte to your python folder from the command-line everytime you want to run the script, you can have your python 'PATH' environment variables set and then you can run the script from any directory.
|
||||||
|
- python install folder: like (C:\Program Files\Python36)
|
||||||
|
- python scripts folder: like (C:\Program Files\Python36\Scripts)
|
||||||
|
|
||||||
## Instructions for Downloading Songs
|
## Instructions for Downloading Songs
|
||||||
|
|
||||||
- For all available options, run `python spotdl.py --help` (or for windows run `python.exe spotdl.py --help`).
|
- For all available options, run `python spotdl.py --help` (or for windows run `python.exe spotdl.py --help`).
|
||||||
|
|||||||
26
spotdl.py
26
spotdl.py
@@ -168,23 +168,17 @@ def downloadSong(content):
|
|||||||
|
|
||||||
def convertWithAvconv(music_file):
|
def convertWithAvconv(music_file):
|
||||||
if os.name == 'nt':
|
if os.name == 'nt':
|
||||||
os.system(
|
avconv_path = 'Scripts\\avconv.exe'
|
||||||
'Scripts\\avconv.exe -loglevel 0 -i "' +
|
|
||||||
'Music/' +
|
|
||||||
music_file +
|
|
||||||
'.m4a" -ab 192k "' +
|
|
||||||
'Music/' +
|
|
||||||
music_file +
|
|
||||||
'.mp3"')
|
|
||||||
else:
|
else:
|
||||||
os.system(
|
avconv_path = 'avconv'
|
||||||
'avconv -loglevel 0 -i "' +
|
os.system(
|
||||||
'Music/' +
|
avconv_path + ' -loglevel 0 -i "' +
|
||||||
music_file +
|
'Music/' +
|
||||||
'.m4a" -ab 192k "' +
|
music_file +
|
||||||
'Music/' +
|
'.m4a" -ab 192k "' +
|
||||||
music_file +
|
'Music/' +
|
||||||
'.mp3"')
|
music_file +
|
||||||
|
'.mp3"')
|
||||||
os.remove('Music/' + music_file + '.m4a')
|
os.remove('Music/' + music_file + '.m4a')
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user