mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-04 08:41:42 -05:00
Incorporate string escaping changes from nixpkgs #108086
This commit is contained in:
parent
2f1fd6a5bd
commit
36f46f7696
2 changed files with 4 additions and 4 deletions
2
lib.nix
2
lib.nix
|
@ -157,7 +157,7 @@ let
|
|||
missingBuildBackendError = "No build-system.build-backend section in pyproject.toml. "
|
||||
+ "Add such a section as described in https://python-poetry.org/docs/pyproject/#poetry-and-pep-517";
|
||||
requires = lib.attrByPath [ "build-system" "requires" ] (throw missingBuildBackendError) pyProject;
|
||||
requiredPkgs = builtins.map (n: lib.elemAt (builtins.match "([^!=<>~\[]+).*" n) 0) requires;
|
||||
requiredPkgs = builtins.map (n: lib.elemAt (builtins.match "([^!=<>~[]+).*" n) 0) requires;
|
||||
in
|
||||
builtins.map (drvAttr: pythonPackages.${drvAttr} or (throw "unsupported build system requirement ${drvAttr}")) requiredPkgs;
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ let
|
|||
inherit (builtins) elemAt match;
|
||||
operators =
|
||||
let
|
||||
matchWildCard = s: match "([^\*])(\.[\*])" s;
|
||||
matchWildCard = s: match "([^*])(\\.[*])" s;
|
||||
mkComparison = ret: version: v: builtins.compareVersions version v == ret;
|
||||
mkIdxComparison = idx: version: v:
|
||||
let
|
||||
|
@ -52,8 +52,8 @@ let
|
|||
#
|
||||
};
|
||||
re = {
|
||||
operators = "([=><!~\^]+)";
|
||||
version = "([0-9\.\*x]+)";
|
||||
operators = "([=><!~^]+)";
|
||||
version = "([0-9.*x]+)";
|
||||
};
|
||||
parseConstraint = constraint:
|
||||
let
|
||||
|
|
Loading…
Add table
Reference in a new issue