Use Package not Application
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
|
||||
outputs = { self, nixpkgs, handyhelper }: let
|
||||
system = "x86_64-linux";
|
||||
handy_py = handyhelper.packages.${system}.handyhelper;
|
||||
handy_py = handyhelper.packages.${system}.handyhelper_pkg;
|
||||
in {
|
||||
nixosConfigurations."staging" = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
|
||||
@@ -11,8 +11,7 @@
|
||||
outputs = { self, nixpkgs, flake-utils, poetry2nix }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
# see https://github.com/nix-community/poetry2nix/tree/master#api for more functions and examples.
|
||||
inherit (poetry2nix.legacyPackages.${system}) mkPoetryApplication mkPoetryEnv;
|
||||
inherit (poetry2nix.legacyPackages.${system}) mkPoetryApplication mkPoetryEnv mkPoetryPackages;
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in rec {
|
||||
|
||||
@@ -23,7 +22,7 @@
|
||||
|
||||
handyhelper = pkgs.runCommand "Handy Helper Deploy" {
|
||||
nativeBuildInputs = [
|
||||
packages.handyhelper
|
||||
packages.handyhelper_pkg
|
||||
];
|
||||
} ''
|
||||
cat << 'DOC' >> $out
|
||||
@@ -44,8 +43,10 @@ DOC
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
packages = {
|
||||
handyhelper = mkPoetryApplication { projectDir = self; };
|
||||
handyhelper_pkg = mkPoetryPackages { projectDir = self; };
|
||||
default = self.packages.${system}.handyhelper;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user