51 lines
1.4 KiB
Nix
51 lines
1.4 KiB
Nix
{
|
|
description = "puzzleYOU release action";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
|
|
pyproject-nix = {
|
|
url = "github:pyproject-nix/pyproject.nix";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
};
|
|
|
|
outputs = { self, nixpkgs, flake-utils, pyproject-nix }:
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
let
|
|
pkgs = import nixpkgs { inherit system; };
|
|
|
|
pythonProject = pyproject-nix.lib.project.loadPyproject {
|
|
projectRoot = ./.;
|
|
};
|
|
|
|
pythonInterpreter = pkgs.python313;
|
|
|
|
pythonPackage = pkgs.python3Packages.buildPythonPackage {
|
|
name = "release-action";
|
|
src = ./.;
|
|
};
|
|
in
|
|
{
|
|
devShells.default = pkgs.mkShell {
|
|
buildInputs = [
|
|
pkgs.envsubst
|
|
pkgs.just
|
|
pkgs.gitea-actions-runner
|
|
(pythonInterpreter.withPackages
|
|
(pythonProject.renderers.withPackages {
|
|
python = pythonInterpreter;
|
|
extraPackages = ps: with ps; [ flake8 isort ];
|
|
}))
|
|
];
|
|
};
|
|
|
|
packages.default = pythonInterpreter.pkgs.buildPythonPackage (
|
|
pythonProject.renderers.buildPythonPackage {
|
|
python = pythonInterpreter;
|
|
});
|
|
}
|
|
);
|
|
}
|