summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorXavierCLL2018-02-25 12:28:50 -0500
committerXavierCLL2018-02-25 12:28:50 -0500
commit060347bd9c5824a8d322eb7bdd431d6bcf6d7a13 (patch)
treea71097d77d1289934b906b8389b70d387eb3f11a
parente9d2cf4235d6080df602d0f900306d2c2225118e (diff)
downloadaur-060347bd9c5824a8d322eb7bdd431d6bcf6d7a13.tar.gz
Fix deps
-rw-r--r--.SRCINFO20
-rw-r--r--PKGBUILD24
-rw-r--r--requirements.txt5
-rwxr-xr-xsetup.py73
4 files changed, 105 insertions, 17 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 3861f51e2f6..70f5e1aaa2e 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,17 @@
-# Generated by mksrcinfo v8
-# Fri Jan 27 23:45:02 UTC 2017
pkgbase = spotify-ripper
pkgdesc = Command-line ripper for Spotify, with a workaround for playlist emptying
pkgver = 2.11
- pkgrel = 1
- url = https://github.com/SolidHal/spotify-ripper
+ pkgrel = 2
+ url = c/
arch = any
license = MIT
makedepends = python2-setuptools
depends = python2
- depends = python2-pyspotify=2.0.5
- depends = python2-colorama-0.3.3
- depends = python2-mutagen-1.30
- depends = python2-requests>=2.3.0
- depends = python2-schedule>=0.3.1
+ depends = mutagen
+ depends = python2-pyspotify
+ depends = python2-colorama
+ depends = python2-requests
+ depends = python2-schedule
depends = python2-spotipy
depends = lame
optdepends = flac: Rip songs to lossless FLAC encoding
@@ -23,7 +21,11 @@ pkgbase = spotify-ripper
optdepends = libav-git-no-libs: Rip songs to Apple Lossless format
optdepends = fdkaac: Rip songs to MP4/M4A format with Fraunhofer FDK AAC codec
source = https://github.com/SolidHal/spotify-ripper/archive/2.11.zip
+ source = setup.py
+ source = requirements.txt
md5sums = 9e15172c41c80eb46b149a3799f9e66a
+ md5sums = 2cc746f3bb1ed00e8bc7dc053829f5dc
+ md5sums = 433ec722cffccd32c7e31807262f1128
pkgname = spotify-ripper
diff --git a/PKGBUILD b/PKGBUILD
index 6c9cf6b548e..6fd959cee8f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,18 +1,26 @@
-_name=spotify-ripper
+# Maintainer: XavierCLL <xavier.corredor.llano (a) gmail.com>
+
pkgname=spotify-ripper
pkgver=2.11
-pkgrel=1
+pkgrel=2
pkgdesc='Command-line ripper for Spotify, with a workaround for playlist emptying'
arch=('any')
-url="https://github.com/SolidHal/$_name"
+url="c/$_name"
license=('MIT')
-depends=('python2' 'python2-pyspotify=2.0.5' 'python2-colorama-0.3.3' 'python2-mutagen-1.30' 'python2-requests>=2.3.0' 'python2-schedule>=0.3.1' 'python2-spotipy' 'lame')
+depends=('python2' 'mutagen' 'python2-pyspotify' 'python2-colorama' 'python2-requests' 'python2-schedule' 'python2-spotipy' 'lame')
optdepends=('flac: Rip songs to lossless FLAC encoding' 'opus-tools: Rip songs to Opus encoding' 'vorbis-tools: Rip songs to Ogg Vorbis encoding' 'faac: Rip songs to AAC format with FreeAAC' 'libav-git-no-libs: Rip songs to Apple Lossless format' 'fdkaac: Rip songs to MP4/M4A format with Fraunhofer FDK AAC codec')
makedepends=('python2-setuptools')
-source=("https://github.com/SolidHal/spotify-ripper/archive/"$pkgver".zip")
-md5sums=('9e15172c41c80eb46b149a3799f9e66a')
+source=("https://github.com/SolidHal/spotify-ripper/archive/$pkgver.zip"
+ "setup.py" "requirements.txt")
+md5sums=('9e15172c41c80eb46b149a3799f9e66a'
+ '2cc746f3bb1ed00e8bc7dc053829f5dc'
+ '433ec722cffccd32c7e31807262f1128')
package() {
- cd "$srcdir/$_name-$pkgver"
- python2 setup.py install --root="$pkgdir" --optimize=1 || return 1
+ # fix imports
+ cp setup.py $pkgname-$pkgver/
+ cp requirements.txt $pkgname-$pkgver/
+
+ cd "$pkgname-$pkgver"
+ python2 setup.py install --root="$pkgdir"
}
diff --git a/requirements.txt b/requirements.txt
new file mode 100644
index 00000000000..6204e4dc47c
--- /dev/null
+++ b/requirements.txt
@@ -0,0 +1,5 @@
+pyspotify
+colorama
+mutagen
+requests
+schedule
diff --git a/setup.py b/setup.py
new file mode 100755
index 00000000000..bcc06861fe6
--- /dev/null
+++ b/setup.py
@@ -0,0 +1,73 @@
+#!/usr/bin/env python
+# coding=utf-8
+
+from setuptools import setup, find_packages
+import os
+
+
+def create_default_dir():
+ default_dir = os.path.normpath(os.path.realpath(
+ (os.path.join(os.path.expanduser("~"), ".spotify-ripper"))))
+ if not os.path.exists(default_dir):
+ print("Creating default settings directory: " +
+ default_dir)
+ os.makedirs(default_dir.encode("utf-8"))
+
+
+def _read(fn):
+ path = os.path.join(os.path.dirname(__file__), fn)
+ return open(path).read()
+
+setup(
+ name='spotify-ripper',
+ version='2.11',
+ packages=find_packages(exclude=["tests"]),
+ scripts=['spotify_ripper/main.py'],
+ include_package_data=True,
+ zip_safe=False,
+
+ # Executable
+ entry_points={
+ 'console_scripts': [
+ 'spotify-ripper = main:main',
+ ],
+ },
+
+ # Additional data
+ package_data={
+ '': ['README.rst', 'LICENCE']
+ },
+
+ # Requirements
+ install_requires=[
+ 'pyspotify',
+ 'colorama',
+ 'mutagen',
+ 'requests',
+ 'schedule',
+ ],
+
+ # Metadata
+ author='James Newell, SolidHal',
+ author_email='james.newell@gmail.com',
+ description='a small ripper for Spotify that rips Spotify URIs '
+ 'to audio files',
+ license='MIT',
+ keywords="spotify ripper mp3 ogg vorbis flac opus acc mp4 m4a",
+ url='https://github.com/SolidHal/spotify-ripper',
+ download_url='https://github.com/SolidHal/spotify-ripper/archive/2.11.tar.gz',
+ classifiers=[
+ 'Topic :: Multimedia :: Sound/Audio',
+ 'Topic :: Multimedia :: Sound/Audio :: Capture/Recording',
+ 'License :: OSI Approved :: MIT License',
+ 'Environment :: Console',
+ "Intended Audience :: Developers",
+ 'Programming Language :: Python :: 2',
+ 'Programming Language :: Python :: 2.7',
+ 'Programming Language :: Python :: 3',
+ 'Programming Language :: Python :: 3.4',
+ ],
+ long_description=_read('README.rst'),
+)
+
+create_default_dir()