mirror of
https://github.com/actions/setup-python.git
synced 2024-11-25 01:38:56 +00:00
fix: allow to pick which version to use by only removing platform_version for this version
This commit is contained in:
parent
427878c2d3
commit
05b0430d2d
3 changed files with 12 additions and 4 deletions
|
@ -27,8 +27,8 @@ inputs:
|
||||||
description: "When 'true', a version range passed to 'python-version' input will match prerelease versions if no GA versions are found. Only 'x.y' version range is supported for CPython."
|
description: "When 'true', a version range passed to 'python-version' input will match prerelease versions if no GA versions are found. Only 'x.y' version range is supported for CPython."
|
||||||
default: false
|
default: false
|
||||||
ignore-platform-version:
|
ignore-platform-version:
|
||||||
description: "Ignore the platform version to allow usage on Debian"
|
description: "Ignore the specific platform version to allow usage on Debian"
|
||||||
default: false
|
default: ""
|
||||||
required: false
|
required: false
|
||||||
outputs:
|
outputs:
|
||||||
python-version:
|
python-version:
|
||||||
|
|
3
dist/setup/index.js
vendored
3
dist/setup/index.js
vendored
|
@ -71732,7 +71732,10 @@ function getManifest() {
|
||||||
// Display each tool
|
// Display each tool
|
||||||
manifest.forEach(tool => {
|
manifest.forEach(tool => {
|
||||||
tool.files.forEach(f => {
|
tool.files.forEach(f => {
|
||||||
|
if (f.platform_version === core.getInput('ignore-platform-version') ||
|
||||||
|
'all' === core.getInput('ignore-platform-version')) {
|
||||||
f.platform_version = undefined;
|
f.platform_version = undefined;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,7 +40,12 @@ export async function getManifest(): Promise<tc.IToolRelease[]> {
|
||||||
// Display each tool
|
// Display each tool
|
||||||
manifest.forEach(tool => {
|
manifest.forEach(tool => {
|
||||||
tool.files.forEach(f => {
|
tool.files.forEach(f => {
|
||||||
|
if (
|
||||||
|
f.platform_version === core.getInput('ignore-platform-version') ||
|
||||||
|
'all' === core.getInput('ignore-platform-version')
|
||||||
|
) {
|
||||||
f.platform_version = undefined;
|
f.platform_version = undefined;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue