nio-llm/flake.nix

41 lines
1,013 B
Nix
Raw Normal View History

2023-05-18 17:04:30 +00:00
{
description = "nio-llm";
2023-05-18 17:07:51 +00:00
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
poetry2nix = {
url = "github:nix-community/poetry2nix";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
2023-05-18 17:04:30 +00:00
};
};
outputs = { nixpkgs, flake-utils, poetry2nix, ... }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [ poetry2nix.overlay ];
};
pythonEnv = pkgs.poetry2nix.mkPoetryEnv {
projectDir = ./.;
preferWheels = true;
python = pkgs.python311;
};
in {
packages.default = pkgs.poetry2nix.mkPoetryApplication {
projectDir = ./.;
preferWheels = true;
python = pkgs.python311;
};
devShells.default =
pkgs.mkShell { buildInputs = [ pythonEnv pkgs.poetry ]; };
});
}