# Maintainer: zoorat # Maintainer: Amin Vakil # Contributor: txtsd # Contributor: Tim Schumacher # Contributor: Felix Yan # Contributor: Gordian Edenhofer pkgname=python-spotdl pkgver=4.2.0 pkgrel=1 pkgdesc='Download your Spotify playlists and songs along with album art and metadata (from YouTube if a match is found).' arch=('any') url='https://github.com/spotDL/spotify-downloader' license=('MIT') depends=( 'ffmpeg' 'python' 'python-bandcamp-api' 'python-beautifulsoup4' 'python-fastapi' 'python-mutagen' 'python-platformdirs' 'python-pydantic' 'python-pykakasi' 'python-pytube' 'python-rapidfuzz' 'python-requests' 'python-rich' 'python-slugify' 'python-spotipy' 'python-syncedlyrics' 'python-typing-extensions' 'python-ytmusicapi' 'uvicorn' 'yt-dlp' ) makedepends=('python-build' 'python-installer' 'python-wheel' 'python-poetry-core') checkdepends=('python-pytest-asyncio') provides=("$pkgname" 'spotdl') options=(strip emptydirs zipman) # install="spotdl.install" source=("https://pypi.io/packages/source/s/spotdl/spotdl-$pkgver.tar.gz") # source=("https://github.com/spotDL/spotify-downloader/archive/refs/tags/v$pkgver.zip") b2sums=('b54689f41cfd5cfeb9b4a6427ac1823f9cd1c846cf8f86eddd82cb17a954f2c210efa6b31ec9d4078822f91eb2b6601f838c3a27df5aef20e81be3dd8bba3b8c') # Document: https://wiki.archlinux.org/title/Python_package_guidelines build() { pushd spotdl-$pkgver # https://github.com/python-poetry/poetry/issues/5547 GIT_DIR=. python -m build --wheel --no-isolation popd } check() { pushd spotdl-$pkgver pytest || echo 'Tests failed!' popd } package() { pushd spotdl-$pkgver python -m installer --destdir="$pkgdir" dist/*.whl install -vDm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" popd }