summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorDan Beste2018-11-16 10:47:01 -0600
committerDan Beste2018-11-16 10:47:01 -0600
commit58f50cc0c4a0256778765a66c9cc3b4eef59d27b (patch)
treeb9c927b3834537e13296e7cc0302098df04edeac /PKGBUILD
downloadaur-58f50cc0c4a0256778765a66c9cc3b4eef59d27b.tar.gz
Initial upload: python-black-git 18.9b0.r13.ge4e59f8-1
* Renamed package: black-git -> python-black-git * Re-added unit tests. * Changed python-setuptools to a dependency. * Added python-aiohttp to checkdepends.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD46
1 files changed, 46 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..e7f483ff36c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,46 @@
+# Maintainer: Dan Beste <Dan.Ray.Beste@gmail.com>
+# Maintainer: Daniel M. Capella <polycitizen@gmail.com>
+
+pkgname='python-black-git'
+pkgver=18.9b0.r13.ge4e59f8
+pkgrel=1
+pkgdesc='Uncompromising code formatter'
+arch=('any')
+url='https://github.com/ambv/black'
+license=('MIT')
+depends=('python-appdirs' 'python-attrs' 'python-click' 'python-setuptools'
+ 'python-toml')
+checkdepends=('python-aiohttp')
+makedepends=('git')
+provides=("${pkgname/-git}")
+conflicts=("${pkgname/-git}")
+source=("${pkgname}::git+$url.git")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "${pkgname}"
+
+ git describe --long --tags \
+ | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+ cd "${pkgname}"
+
+ python setup.py build
+}
+
+check() {
+ cd "${pkgname}"
+
+ python -m unittest tests/test_black.py
+}
+
+package() {
+ cd "${pkgname}"
+
+ python setup.py install --root="$pkgdir" --optimize=1 --skip-build
+ install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
+
+# vim:set ts=2 sw=2 et: