summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 1883cb1ca52befa5b1b4dfe0857da2b3c7888f37 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# Maintainer: Jiachen Yang <farseerfc@gmail.com>
# Maintainer: Ariel AxionL <axiionl@aosc.io>

pkgname=netease-musicbox
_gitname=musicbox
_pyname=NetEase-MusicBox
pkgver=0.3.1
pkgrel=2
pkgdesc="A sexy command line interface musicbox for NetEase based on Python"
arch=(any)
url="https://github.com/darknessomi/musicbox"
depends=('mpg123' 'python-pycryptodomex' 'python-requests' 'python-future' 
         'python-fuzzywuzzy' 'python-requests-cache' 'python-importlib-metadata')
makedepends=('python-setuptools' 'python-poetry')
optdepends=('aria2: music caching'
            'libnotify: notifications'
            'qt5-base: lyrics support'
            'python-qtpy: lyrics support'
            'python-pyqt5: lyrics support'
            'python-dbus: lyrics support'
            'python-levenshtein: fuzzy search support')
provides=('musicbox')
conflicts=('netease-musicbox-git')
license=('MIT')

source=("musicbox-$pkgver.tar.gz::https://github.com/darknessomi/musicbox/archive/${pkgver}.tar.gz"
        "LICENSE::https://raw.githubusercontent.com/darknessomi/musicbox/master/LICENSE")

sha256sums=('b7f984b0462b553ebc8fccb414783b07936efa49fdd1822d2c79a4c8aa624f4e'
            '40aaf7aea7939284b07c487929472fa9cc5a842ff5f0c1e474ac93e6de7aa64e')

build() {
    cd "${srcdir}/musicbox-${pkgver}"
    poetry build -f sdist
    tar xvf "./dist/${_pyname}-${pkgver}.tar.gz"
}

package() {
    install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"

    cd "${srcdir}/musicbox-${pkgver}"/${_pyname}-${pkgver}
    python setup.py install --root="${pkgdir}/" --optimize=1
}
# vim:set ts=4 sw=4 et: