Merge pull request #273477 from charles-dyfis-net/poetry-compose-overrides

This commit is contained in:
Franz Pletz 2024-01-15 02:25:49 +01:00 committed by GitHub
commit 87b9bf8ea4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,8 +1,8 @@
{ python3, fetchFromGitHub }:
{ lib, python3, fetchFromGitHub }:
let
python = python3.override {
packageOverrides = self: super: rec {
newPackageOverrides =
self: super: {
poetry = self.callPackage ./unwrapped.nix { };
# The versions of Poetry and poetry-core need to match exactly,
@ -21,7 +21,10 @@ let
};
});
} // (plugins self);
};
python = python3.override (old: {
packageOverrides = lib.composeManyExtensions
((if old ? packageOverrides then [ old.packageOverrides ] else [ ]) ++ [ newPackageOverrides ]);
});
plugins = ps: with ps; {
poetry-audit-plugin = callPackage ./plugins/poetry-audit-plugin.nix { };