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

Felix Yan felixonmars at archlinux.org
Tue Nov 10 04:01:43 UTC 2020


    Date: Tuesday, November 10, 2020 @ 04:01:43
  Author: felixonmars
Revision: 748377

archrelease: copy trunk to community-staging-any

Added:
  autopep8/repos/community-staging-any/
  autopep8/repos/community-staging-any/PKGBUILD
    (from rev 748373, autopep8/trunk/PKGBUILD)

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

Copied: autopep8/repos/community-staging-any/PKGBUILD (from rev 748373, autopep8/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD	                        (rev 0)
+++ community-staging-any/PKGBUILD	2020-11-10 04:01:43 UTC (rev 748377)
@@ -0,0 +1,59 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Ismael Carnales <icarnales at gmail dot com>
+# Contributor: Sergey Mastykov <smastykov[at]gmail[dot]com>
+
+pkgbase=autopep8
+pkgname=(autopep8 python2-autopep8)
+pkgver=1.5.4
+pkgrel=2
+epoch=1
+pkgdesc="A tool that automatically formats Python code to conform to the PEP 8 style guide"
+arch=('any')
+url="https://github.com/hhatto/autopep8"
+license=('MIT')
+makedepends=('python-pycodestyle' 'python2-pycodestyle' 'python-toml' 'python2-toml')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/hhatto/autopep8/archive/v$pkgver.tar.gz")
+sha512sums=('f830ca310616e1a151b3d7c78b61ec6d33db19c123d673729dc14ebd858e1f150d9405081a1fab30fbeac3ef59a5c216f1dd2a120623e7f3deb2770cc1854ad1')
+
+prepare() {
+  cp -a autopep8-$pkgver{,-py2}
+}
+
+build() {
+  cd "$srcdir"/autopep8-$pkgver
+  python setup.py build
+
+  cd "$srcdir"/autopep8-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  export LC_CTYPE=en_US.UTF-8
+
+  cd "$srcdir"/autopep8-$pkgver
+  python setup.py test
+
+  cd "$srcdir"/autopep8-$pkgver-py2
+  python2 setup.py test
+}
+
+package_autopep8() {
+  depends=('python-pycodestyle' 'python-toml')
+
+  cd autopep8-$pkgver
+  python3 setup.py install -O1 --prefix=/usr --root="$pkgdir"
+
+  install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-autopep8() {
+  depends=('python2-pycodestyle' 'python2-toml')
+
+  cd autopep8-$pkgver-py2
+  python2 setup.py install -O1 --prefix=/usr --root="$pkgdir"
+  mv "$pkgdir"/usr/bin/autopep8{,-python2}
+
+  install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+# vim:set ts=2 sw=2 et:


More information about the arch-commits mailing list