diff options
| author | Anderson Bravalheri <andersonbravalheri@gmail.com> | 2021-12-21 19:52:37 +0000 |
|---|---|---|
| committer | Anderson Bravalheri <andersonbravalheri@gmail.com> | 2021-12-21 19:52:37 +0000 |
| commit | 7479892c117dc739d26f8c957c1b761870d192fa (patch) | |
| tree | 8a9ef10f889b56f0e0c1556e2d92a555a6b75e02 /pavement.py | |
| parent | 9441be71d3041f30a503cf551a6ca70d8f9bc7cf (diff) | |
| download | python-setuptools-git-7479892c117dc739d26f8c957c1b761870d192fa.tar.gz | |
Remove license lookup in *.egg-info
I believe that only wheels install licenses in the *.dist-info.
Diffstat (limited to 'pavement.py')
| -rw-r--r-- | pavement.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/pavement.py b/pavement.py index 1cebad79..d588e5ae 100644 --- a/pavement.py +++ b/pavement.py @@ -1,7 +1,6 @@ import re import sys import subprocess -from itertools import chain from fnmatch import fnmatch from paver.easy import task, path as Path @@ -65,7 +64,7 @@ def move_licenses(vendor): license_patterns = ("*LICEN[CS]E*", "COPYING*", "NOTICE*", "AUTHORS*") licenses = ( entry - for path in chain(vendor.glob("*.dist-info"), vendor.glob("*.egg-info")) + for path in vendor.glob("*.dist-info") for entry in path.glob("*") if any(fnmatch(str(entry), p) for p in license_patterns) ) @@ -75,7 +74,7 @@ def move_licenses(vendor): def _find_license_dest(license_file, vendor): basename = license_file.basename() - pkg = license_file.dirname().replace(".dist-info", "").replace(".egg-info", "") + pkg = license_file.dirname().replace(".dist-info", "") parts = pkg.split("-") acc = [] for part in parts: |
