feat: can now call 'nix run' on it

For instance nix run poetry#. -- lock -v or something similar.
you can override the nixpkgs input if you dont want to redownload
it, or just lock everything.
This commit is contained in:
Matthieu Coudron 2020-12-01 12:44:48 +01:00
parent 034761d214
commit 797970c69d

View file

@ -16,15 +16,22 @@
); );
in in
{ {
overlay = import ./overlay.nix; overlay = import ./overlay.nix;
# TODO: I feel like `packages` is the wrong place for the poetry2nix attr packages = forAllSystems (system: {
packages = forAllSystems ( inherit (nixpkgsFor.${system}) poetry;
system: { }
inherit (nixpkgsFor.${system}) poetry poetry2nix;
}
); );
apps = forAllSystems (system: {
poetry = {
type = "app";
program = self.packages."${system}".poetry + "/bin/poetry";
};
});
defaultApp = forAllSystems (system:
self.apps."${system}".poetry
);
}; };
} }