summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 408105c7d0f3979094ec84d7b7bf7b8730f27d81 (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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# Maintainer: Astro Benzene <universebenzene at sina dot com>
pkgbase=python-pydata-sphinx-theme
_pname=${pkgbase#python-}
_pyname=${_pname//-/_}
pkgname=("python-${_pname}")
#"python-${_pname}-doc")
pkgver=0.16.0
pkgrel=1
pkgdesc="Bootstrap-based Sphinx theme from the PyData community"
arch=('any')
url="https://pydata-sphinx-theme.readthedocs.io"
license=('BSD-3-Clause')
makedepends=('python-installer')
#makedepends=('python-sphinx-theme-builder'
#             'python-flit-core'
#             'python-build'
#             'python-installer'
#             'nodejs-lts-gallium'
#             'npm'
#             'python-beautifulsoup4'
#             'python-jupyter-sphinx'
#             'python-myst-parser'
#             'python-numpydoc'
#             'python-sphinxext-rediraffe'
#             'python-sphinx-sitemap'
#             'python-pandas'
#             'python-plotly'
#             'python-tenacity'
#             'python-xarray')
#checkdepends=('python-pytest-regressions')
checkdepends=('python-nose'
              'python-requests'
              'python-beautifulsoup4'
              'python-sphinx')
#source=("https://files.pythonhosted.org/packages/source/${_pyname:0:1}/${_pyname}/${_pyname}-${pkgver}.tar.gz"
#        'Makefile')
source=("https://files.pythonhosted.org/packages/py3/${_pyname:0:1}/${_pyname}/${_pyname//-/_}-${pkgver}-py3-none-any.whl")
md5sums=('1eec278af31f4e5529cd14df9f06420f')

#prepare() {
#    cd ${srcdir}/${_pyname}-${pkgver}
#
#    ln -s ${srcdir}/Makefile docs
#    mkdir bin
#    ln -s /usr/bin/node bin/nodejs
#}

#build() {
#    cd ${srcdir}/${_pyname}-${pkgver}
#    PATH="${PWD}/bin:${PATH}" python -m build --wheel --no-isolation
#
#    msg "Building Docs"
#    mkdir dist/lib
#    bsdtar -xpf dist/${_pyname}-${pkgver}-py3-none-any.whl -C dist/lib
#    cd ${srcdir}/${_pyname}-${pkgver}/docs
#    PYTHONPATH="../dist/lib" make html
#}

check() {
#   cd ${srcdir}/${_pyname}-${pkgver}

#   PYTHONPATH="dist/lib" pytest || warning "Tests failed" # -vv --color=yes
    nosetests || warning "Tests failed" # -v -x
}

package_python-pydata-sphinx-theme() {
    depends=('python-sphinx>=6.1'
             'python-beautifulsoup4'
             'python-docutils>0.17.0'
             'python-packaging'
             'python-babel'
             'python-accessible-pygments'
             'python-typing_extensions')    # pygments required by accessible-pygments
#   cd ${srcdir}/${_pyname}-${pkgver}

#   install -D -m644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
    install -D -m644 ${_pyname//-/_}-${pkgver}.dist-info/LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
#   install -D -m644 README.md -t "${pkgdir}/usr/share/doc/${pkgname}"
    python -m installer --destdir="${pkgdir}" ${srcdir}/${_pyname//-/_}-${pkgver}-py3-none-any.whl
#   python -m installer --destdir="${pkgdir}" dist/*.whl
}

#package_python-pydata-sphinx-theme-doc() {
#    pkgdesc="Documentation for PyData Sphinx Theme"
#    cd ${srcdir}/${_pyname}-${pkgver}/docs/_build
#
#    install -D -m644 -t "${pkgdir}/usr/share/licenses/${pkgname}" ../../LICENSE
#    install -d -m755 "${pkgdir}/usr/share/doc/${pkgbase}"
#    cp -a html "${pkgdir}/usr/share/doc/${pkgbase}"
#}