mirror of
https://github.com/astral-sh/setup-uv.git
synced 2025-12-21 11:01:40 +00:00
Ignore backslashes and whitespace in requirements (#501)
setup-uv gets confused when there are backslashes in `requirements.txt`. This changes the regex to ignore backslashes. --------- Co-authored-by: axm2 <>
This commit is contained in:
2
dist/setup/index.js
generated
vendored
2
dist/setup/index.js
generated
vendored
@@ -125910,7 +125910,7 @@ function getUvVersionFromRequirementsFile(filePath) {
|
||||
function getUvVersionFromAllDependencies(allDependencies) {
|
||||
return allDependencies
|
||||
.find((dep) => dep.match(/^uv[=<>~!]/))
|
||||
?.match(/^uv([=<>~!]+.*)$/)?.[1]
|
||||
?.match(/^uv([=<>~!]+\S*)/)?.[1]
|
||||
.trim();
|
||||
}
|
||||
function parsePyprojectDependencies(pyprojectContent) {
|
||||
|
||||
Reference in New Issue
Block a user