[arch-commits] Commit in python-jsbeautifier/repos (2 files)

Evangelos Foutras foutrelis at archlinux.org
Sun Jul 8 13:47:12 UTC 2018


    Date: Sunday, July 8, 2018 @ 13:47:12
  Author: foutrelis
Revision: 354906

archrelease: copy trunk to community-staging-any

Added:
  python-jsbeautifier/repos/community-staging-any/
  python-jsbeautifier/repos/community-staging-any/PKGBUILD
    (from rev 354905, python-jsbeautifier/trunk/PKGBUILD)

----------+
 PKGBUILD |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 55 insertions(+)

Copied: python-jsbeautifier/repos/community-staging-any/PKGBUILD (from rev 354905, python-jsbeautifier/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD	                        (rev 0)
+++ community-staging-any/PKGBUILD	2018-07-08 13:47:12 UTC (rev 354906)
@@ -0,0 +1,55 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-jsbeautifier
+pkgname=('python-jsbeautifier' 'python2-jsbeautifier')
+pkgver=1.7.5
+pkgrel=2
+pkgdesc='JavaScript unobfuscator and beautifier'
+arch=('any')
+license=('MIT')
+url='https://github.com/beautify-web/js-beautify'
+makedepends=('python-setuptools' 'python2-setuptools' 'python-editorconfig' 'python2-editorconfig')
+checkdepends=('python-pytest' 'python2-pytest')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/beautify-web/js-beautify/archive/v$pkgver.tar.gz")
+sha512sums=('873b84ee7d10d0db9e6de6e6ba170d7beebafcb16bca262b5ad6db644d6bfbac6c4ad7cd3b6774ad002224720d6a1e520f78c019a9c846cea5a3dab73e1a26b8')
+
+prepare() {
+  cp -a js-beautify-$pkgver{,-py2}
+}
+
+build() {
+  cd "$srcdir"/js-beautify-$pkgver/python
+  python setup.py build
+
+  cd "$srcdir"/js-beautify-$pkgver-py2/python
+  python2 setup.py build
+}
+
+check() {
+  cd "$srcdir"/js-beautify-$pkgver/python
+  python setup.py test
+
+  cd "$srcdir"/js-beautify-$pkgver-py2/python
+  python2 setup.py test
+}
+
+package_python-jsbeautifier() {
+  depends=('python-six' 'python-editorconfig')
+
+  cd js-beautify-$pkgver/python
+  python setup.py install --root="$pkgdir" --optimize=1
+  install -D -m644 ../LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-jsbeautifier() {
+  depends=('python2-six' 'python2-editorconfig')
+
+  cd js-beautify-$pkgver-py2/python
+  python2 setup.py install --root="$pkgdir" --optimize=1
+  install -D -m644 ../LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+
+  mv "$pkgdir"/usr/bin/js-beautify{,2}
+}
+
+# vim:set ts=2 sw=2 et:



More information about the arch-commits mailing list