Files
passwd2systemd-users/flake.nix
T
2026-05-29 22:27:34 +09:00

42 lines
1.0 KiB
Nix

{
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
outputs = { self, nixpkgs }: let
inherit (nixpkgs) lib;
systems = [
"x86_64-linux"
"aarch64-linux"
"x86_64-darwin"
"aarch64-darwin"
"armv7l-linux"
];
forAllSystems = f: lib.genAttrs systems (system: f system nixpkgs.legacyPackages.${system});
in {
devShells = forAllSystems (_: pkgs: {
default = pkgs.mkShell {
packages = with pkgs; [
python3
ruff
];
};
});
packages = forAllSystems (_: pkgs: {
default = lib.pipe ./main.py [
lib.readFile
(lib.splitString "\n")
lib.tail
(lib.concatStringsSep "\n")
(pkgs.writers.writePython3Bin "passwd2systemd-users" {
libraries = with pkgs.python3Packages; [ ];
flakeIgnore = [
"E501" # I absolutely love and adore long lines, please let every single line be above 80 characters please
];
})
];
});
};
}