mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-05 17:21:39 -05:00
cleanup: reorganize flake a bit, export lib.mkPoetry2Nix as a function
This commit is contained in:
parent
8f2c483f9a
commit
22b31f0c29
2 changed files with 4 additions and 19 deletions
21
flake.nix
21
flake.nix
|
@ -22,6 +22,7 @@
|
|||
|
||||
{
|
||||
overlay = import ./overlay.nix;
|
||||
lib.mkPoetry2Nix = { pkgs }: import ./default.nix { inherit pkgs; };
|
||||
|
||||
githubActions =
|
||||
let
|
||||
|
@ -71,27 +72,11 @@
|
|||
let
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
overlays = [
|
||||
(_: _: {
|
||||
p2nix-tools = pkgs.callPackage ./tools { };
|
||||
})
|
||||
];
|
||||
config = {
|
||||
allowAliases = false;
|
||||
permittedInsecurePackages = [
|
||||
"python3.8-requests-2.29.0"
|
||||
"python3.8-cryptography-40.0.2"
|
||||
"python3.9-requests-2.29.0"
|
||||
"python3.9-cryptography-40.0.2"
|
||||
"python3.10-requests-2.29.0"
|
||||
"python3.10-cryptography-40.0.2"
|
||||
"python3.11-requests-2.29.0"
|
||||
"python3.11-cryptography-40.0.2"
|
||||
];
|
||||
};
|
||||
config.allowAliases = false;
|
||||
};
|
||||
|
||||
poetry2nix = import ./default.nix { inherit pkgs; };
|
||||
p2nix-tools = pkgs.callPackage ./tools { };
|
||||
in
|
||||
rec {
|
||||
formatter = treefmtEval.${system}.config.build.wrapper;
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
let
|
||||
# see https://github.com/nix-community/poetry2nix/tree/master#api for more functions and examples.
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
inherit (import poetry2nix { inherit pkgs; }) mkPoetryApplication;
|
||||
inherit (poetry2nix.lib.mkPoetry2Nix { inherit pkgs; }) mkPoetryApplication;
|
||||
in
|
||||
{
|
||||
packages = {
|
||||
|
|
Loading…
Add table
Reference in a new issue