Changes for v1.0.0 release (#345)

* Move spotdl.py inside spotdl directory

* Fix Dockerfile

* Re-upload FFmpeg binary

* Small fixes ;)
This commit is contained in:
Ritiek Malhotra
2018-09-09 08:00:01 -07:00
committed by GitHub
parent a7e9009aa6
commit e0c8960906
21 changed files with 51 additions and 73 deletions

View File

@@ -35,7 +35,7 @@ addons:
- libav-tools
install:
- pip install -e .
- tinydownload 22684734659253158385 -o ~/bin/ffmpeg
- tinydownload 07426048687547254773 -o ~/bin/ffmpeg
- chmod 755 ~/bin/ffmpeg
- xdg-user-dirs-update
script: python -m pytest test --cov=.

View File

@@ -3,14 +3,14 @@ FROM python:3.6-alpine
RUN apk add --no-cache \
ffmpeg
ADD requirements.txt /spotify-downloader/
RUN pip install -r /spotify-downloader/requirements.txt
RUN rm /spotify-downloader/requirements.txt
ADD spotdl/ /spotify-downloader/spotdl
ADD setup.py /spotify-downloader/setup.py
ADD README.md /spotify-downloader/README.md
ADD spotdl.py /spotify-downloader/
ADD core/ /spotify-downloader/core
WORKDIR /spotify-downloader
RUN pip install .
RUN mkdir /music
WORKDIR /music
ENTRYPOINT ["python3", "/spotify-downloader/spotdl.py", "-f", "/music"]
ENTRYPOINT ["spotdl", "-f", "/music"]

View File

@@ -1 +0,0 @@

View File

@@ -1,12 +0,0 @@
pathlib >= 1.0.1
youtube_dl >= 2017.5.1
pafy >= 0.5.3.1
spotipy >= 2.4.4
mutagen >= 1.37
beautifulsoup4 >= 4.6.0
unicode-slugify >= 0.1.3
titlecase >= 0.10.0
logzero >= 1.3.1
lyricwikia >= 0.1.8
PyYAML >= 3.12
appdirs >= 1.4.3

View File

@@ -6,15 +6,7 @@ from setuptools import setup
with open('README.md', 'r') as f:
long_description = f.read()
# This does not work as the dependencies imported are most
# likely just about to be installed :/
# from spotdl import __version__
_version_re = re.compile(r'__version__\s+=\s+(.*)')
with open('spotdl.py', 'r') as f:
version = str(ast.literal_eval(_version_re.search(f.read()).group(1)))
import spotdl
setup(
# 'spotify-downloader' was already taken :/
@@ -22,11 +14,11 @@ setup(
py_modules=['spotdl'],
# Tests are included automatically:
# https://docs.python.org/3.6/distutils/sourcedist.html#specifying-the-files-to-distribute
packages=['core'],
version=version,
packages=['spotdl'],
version=spotdl.__version__,
install_requires=[
'pathlib >= 1.0.1',
'youtube_dl >= 2017.5.1',
'youtube_dl >= 2017.9.8',
'pafy >= 0.5.3.1',
'spotipy >= 2.4.4',
'mutagen >= 1.37',
@@ -64,7 +56,7 @@ setup(
],
entry_points={
'console_scripts': [
'spotdl = spotdl:main',
'spotdl = spotdl.spotdl:main',
],
}
)

1
spotdl/__init__.py Executable file
View File

@@ -0,0 +1 @@
__version__ = '1.0.0'

View File

@@ -1,6 +1,6 @@
import subprocess
import os
from core.const import log
from spotdl.const import log
"""What are the differences and similarities between ffmpeg, libav, and avconv?

View File

@@ -1,5 +1,5 @@
import appdirs
from core import internals, const
from spotdl import internals, const
log = const.log

View File

@@ -1,7 +1,7 @@
import os
import sys
from core import const
from spotdl import const
log = const.log

View File

@@ -2,7 +2,7 @@ from mutagen.easyid3 import EasyID3
from mutagen.id3 import ID3, TORY, TYER, TPUB, APIC, USLT, COMM
from mutagen.mp4 import MP4, MP4Cover
from mutagen.flac import Picture, FLAC
from core.const import log, TAG_PRESET, M4A_TAG_PRESET
from spotdl.const import log, TAG_PRESET, M4A_TAG_PRESET
import urllib.request

View File

@@ -1,12 +1,12 @@
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
from core import const
from core import handle
from core import metadata
from core import convert
from core import internals
from core import spotify_tools
from core import youtube_tools
from spotdl import const
from spotdl import handle
from spotdl import metadata
from spotdl import convert
from spotdl import internals
from spotdl import spotify_tools
from spotdl import youtube_tools
from slugify import slugify
import spotipy
import urllib.request
@@ -16,8 +16,6 @@ import time
import platform
import pprint
__version__ = '0.9.3'
def check_exists(music_file, raw_song, meta_tags):
""" Check if the input song already exists in the given folder. """

View File

@@ -2,8 +2,8 @@ import spotipy
import spotipy.oauth2 as oauth2
import lyricwikia
from core import internals
from core.const import log
from spotdl import internals
from spotdl.const import log
from slugify import slugify
from titlecase import titlecase

View File

@@ -2,8 +2,8 @@ from bs4 import BeautifulSoup
import urllib
import pafy
from core import internals
from core import const
from spotdl import internals
from spotdl import const
import os
import pprint

View File

@@ -1,6 +1,6 @@
from core import const
from core import handle
import spotdl
from spotdl import const
from spotdl import handle
from spotdl import spotdl
import pytest

View File

@@ -1,6 +1,6 @@
from core import const
from spotdl import const
import spotdl
from spotdl import spotdl
import loader
import os

View File

@@ -1,7 +1,7 @@
import yaml
from core import handle
from core import const
from spotdl import handle
from spotdl import const
import pytest
import os

View File

@@ -1,4 +1,4 @@
from core import internals
from spotdl import internals
import sys
import os

View File

@@ -1,7 +1,7 @@
from core import spotify_tools
from core import const
from spotdl import spotify_tools
from spotdl import const
import spotdl
from spotdl import spotdl
import builtins
import os

View File

@@ -1,12 +1,12 @@
from core import const
from core import internals
from core import spotify_tools
from core import youtube_tools
from core import convert
from core import metadata
from spotdl import const
from spotdl import internals
from spotdl import spotify_tools
from spotdl import youtube_tools
from spotdl import convert
from spotdl import metadata
import spotdl
from spotdl import spotdl
import loader
import os

View File

@@ -1,9 +1,9 @@
from core import const
from core import internals
from core import spotify_tools
from core import youtube_tools
from spotdl import const
from spotdl import internals
from spotdl import spotify_tools
from spotdl import youtube_tools
import spotdl
from spotdl import spotdl
import loader
import os