forked from pool/python-autoflake
Accepting request 673161 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/673161 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-autoflake?expand=0&rev=3
This commit is contained in:
19
LICENSE
19
LICENSE
@@ -1,19 +0,0 @@
|
||||
Copyright (C) 2012-2018 Steven Myint
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is furnished to do
|
||||
so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:a74d684a7a02654f74582addc24a3016c06809316cc140457a4fe93a1e6ed131
|
||||
size 17242
|
||||
3
autoflake-1.2.tar.gz
Normal file
3
autoflake-1.2.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:c103e63466f11db3617167a2c68ff6a0cda35b940222920631c6eeec6b67e807
|
||||
size 17470
|
||||
@@ -1,41 +0,0 @@
|
||||
From d1fe6ad670c890cce5cdbb430a438453da65f015 Mon Sep 17 00:00:00 2001
|
||||
From: toddrme2178 <toddrme2178@gmail.com>
|
||||
Date: Tue, 13 Feb 2018 15:39:57 -0500
|
||||
Subject: [PATCH] standard_paths in plat_specific True and False
|
||||
|
||||
Have `standard_paths` look in both platform-specific and platform-independent directories. Fixes issue #32.
|
||||
---
|
||||
autoflake.py | 18 ++++++++++--------
|
||||
1 file changed, 10 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/autoflake.py b/autoflake.py
|
||||
index 3918280..8d75dfb 100755
|
||||
--- a/autoflake.py
|
||||
+++ b/autoflake.py
|
||||
@@ -68,16 +68,18 @@
|
||||
|
||||
def standard_paths():
|
||||
"""Yield paths to standard modules."""
|
||||
- path = distutils.sysconfig.get_python_lib(standard_lib=True)
|
||||
+ for is_plat_spec in [True, False]:
|
||||
+ path = distutils.sysconfig.get_python_lib(standard_lib=True,
|
||||
+ plat_specific=is_plat_spec)
|
||||
|
||||
- for name in os.listdir(path):
|
||||
- yield name
|
||||
-
|
||||
- try:
|
||||
- for name in os.listdir(os.path.join(path, 'lib-dynload')):
|
||||
+ for name in os.listdir(path):
|
||||
yield name
|
||||
- except OSError: # pragma: no cover
|
||||
- pass
|
||||
+
|
||||
+ try:
|
||||
+ for name in os.listdir(os.path.join(path, 'lib-dynload')):
|
||||
+ yield name
|
||||
+ except OSError: # pragma: no cover
|
||||
+ pass
|
||||
|
||||
|
||||
def standard_package_names():
|
||||
@@ -1,3 +1,15 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 10 13:50:19 UTC 2019 - John Vandenberg <jayvdb@gmail.com>
|
||||
|
||||
- Update to v1.2
|
||||
+ Have `standard_paths` look in both platform-specific and
|
||||
platform-independent directories
|
||||
(replaces fix_standard_paths.patch)
|
||||
+ Add LICENSE
|
||||
+ Drop Python 3.3
|
||||
- Remove unnecessary build dependency %pythons
|
||||
- Remove unused build dependency 'coverage'
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 5 01:54:31 UTC 2018 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-autoflake
|
||||
#
|
||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -19,7 +19,7 @@
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
%bcond_without test
|
||||
Name: python-autoflake
|
||||
Version: 1.1
|
||||
Version: 1.2
|
||||
Release: 0
|
||||
# for license file
|
||||
%define tag 44b07bb9dab60a74cb5da0b67cc78b734763785c
|
||||
@@ -28,15 +28,10 @@ License: MIT
|
||||
Group: Development/Languages/Python
|
||||
Url: https://github.com/myint/autoflake
|
||||
Source: https://files.pythonhosted.org/packages/source/a/autoflake/autoflake-%{version}.tar.gz
|
||||
Source10: https://raw.githubusercontent.com/myint/autoflake/%{tag}/LICENSE
|
||||
# PATCH-FIX-UPSTREAM fix_standard_paths.patch -- https://github.com/myint/autoflake/issues/32
|
||||
Patch0: fix_standard_paths.patch
|
||||
BuildRequires: %pythons
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
%if %{with test}
|
||||
BuildRequires: %{python_module coverage}
|
||||
BuildRequires: %{python_module pyflakes >= 1.1.0}
|
||||
%endif
|
||||
Requires: python-pyflakes >= 1.1.0
|
||||
@@ -59,9 +54,6 @@ autoflake also removes useless pass statements.
|
||||
|
||||
%prep
|
||||
%setup -q -n autoflake-%{version}
|
||||
cp %{SOURCE10} .
|
||||
%patch0 -p1
|
||||
sed -i -e '/^#!\//, 1d' autoflake.py
|
||||
|
||||
%build
|
||||
%python_build
|
||||
|
||||
Reference in New Issue
Block a user