| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: David Seifert <soap@gentoo.org>
|
|
|
|
|
|
|
|
| |
Implement automatic translation _pre to .dev for pypi SRC_URIs.
Signed-off-by: Tom Gillespie <tgbugs@gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/31861
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change _pypi_normalize_name() to reset extglob unconditionally. This
function is called only in two contexts:
- inside a subshell, therefore making it unnecessary to restore
the original extglob value,
- in global scope, via _pypi_set_globals, where we know that extglob
is not supposed to be set.
This makes the code simpler.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Closes: https://github.com/gentoo/gentoo/pull/31465
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Suggested by Eli Schwartz. This gives roughly 5260 ops / s, over 550%
speedup.
The complete patch series therefore increases the speed from roughly
326 ops / s to 5260 ops / s, making the common case 16 times faster.
Closes: https://bugs.gentoo.org/908411
Closes: https://github.com/gentoo/gentoo/pull/31404
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
| |
Introduce an internal helper for _pypi_sdist_url that doesn't require
subshell, and therefore eliminate all subshells from global scope.
We're nearing 952 ops / s, further 39% speedup.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
| |
Provide an internal helper to translate versions without a subshell,
and use it in the common case. Now the benchmark gives 685 ops / s,
which means it's another 28% speedup.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
| |
Provide an internal helper to normalize names without a subshell.
This gives 535 ops / s, so a further 44% speedup.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
| |
Instead of translating version two times, once in pypi_sdist_url
and then when setting S, do it once and store the result. This gives
roughly 371 ops / s, i.e. a 13% speedup.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
| |
Thanks to codespell.
Signed-off-by: Sam James <sam@gentoo.org>
Signed-off-by: Ulrich Müller <ulm@gentoo.org>
|
|
|
|
|
|
| |
This avoids globbing, see: https://www.shellcheck.net/wiki/SC2223
Signed-off-by: Ulrich Müller <ulm@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Introduce a convenience PYPI_PN variable that can be used to override
the default project name. This is meant to be used primarily when
upstream project name does not conform to Gentoo package naming rules,
e.g. contains dots or uppercase letters.
For example, instead of:
SRC_URI="$(pypi_sdist_url --no-normalize "${PN/-/.}")"
S=${WORKDIR}/${P/-/.}
one can now specify:
PYPI_NO_NORMALIZE=1
PYPI_PN=${PN/-/.}
For PEP 625-conformant packages, instead of:
SRC_URI="$(pypi_sdist_url "${PN/-/.}")"
one can use:
PYPI_PN=${PN/-/.}
There's not much gain space-wise but it avoids having to specify
the name twice. This can particularly be helpful for package names
using PascalCase.
Closes: https://github.com/gentoo/gentoo/pull/30210
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
| |
Closes: https://github.com/gentoo/gentoo/pull/29526
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
|
|
|
|
|
|
| |
Add a handy `--unpack` option to pypi_wheel_url, that automatically
renames the downloaded distfile to have .zip suffix. This is used
e.g. in dev-python/installer and dev-python/tomli to have
default_src_unpack unpack the wheels automatically.
Closes: https://github.com/gentoo/gentoo/pull/29439
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
|
|
| |
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|
|
Closes: https://github.com/gentoo/gentoo/pull/29361
Signed-off-by: Michał Górny <mgorny@gentoo.org>
|