Package Details: python-autoflake 1.3.1-2

Git Clone URL: (read-only, click to copy)
Package Base: python-autoflake
Description: Removes unused imports and unused variables
Upstream URL:
Keywords: linter python
Licenses: MIT
Submitter: andreao
Maintainer: pancho
Last Packager: pancho
Votes: 3
Popularity: 0.002547
First Submitted: 2018-09-20 22:55
Last Updated: 2020-06-30 05:59

Latest Comments

andreao commented on 2019-09-22 08:39

Thanks! Updated.

goetzc commented on 2019-09-22 00:17

@blueyed is right, the binary is not installed in a standard PATH directory, it also should depend on pylakes and it uses a non-standard build mechanism. Please updated it, you can use the following working patch:

diff --git a/PKGBUILD b/PKGBUILD
index 012901e..20a4819 100644
@@ -1,17 +1,24 @@
-# PKGBUILD generated by pipman
 # Python package author: Steven Myint <UNKNOWN>
 pkgdesc="Removes unused imports and unused variables"
-license=(Expat License)
-makedepends=("python" "python-pip")
 build() {
-  pip install --no-deps --target="autoflake" autoflake
+  cd "$srcdir/$_pkgname-$pkgver"
+  python build
 package() {
-  mkdir -p $pkgdir/usr/lib/python3.7/site-packages/
-  cp -r $srcdir/autoflake/* $pkgdir/usr/lib/python3.7/site-packages/
+  cd "$srcdir/$_pkgname-$pkgver"
+  python install --root="$pkgdir/" --optimize=1

blueyed commented on 2019-01-20 13:10

The package does not install the autoflake binary properly, but copies it to site-packages also.

I think the PKGBUILD should look more like this:

build() {
  cd "$srcdir/python-autoflake-$pkgver"
  python build

package() {
  cd "$srcdir/python-autoflake-$pkgver"
  python install --root="$pkgdir/" --optimize=1