nixos-config/flake.nix
2024-11-05 17:00:34 +01:00

98 lines
3 KiB
Nix

{
outputs = inputs:
inputs.flake-parts.lib.mkFlake {
inherit inputs;
} {
systems = ["x86_64-linux"];
imports = [
./home/profiles
./hosts/machines
./modules
./home-modules
];
flake = {
};
perSystem = {pkgs, ...}: {
devShells.default = pkgs.mkShell {
packages = with pkgs; [
alejandra
nil
nixd
git
just
home-manager
sops
## TODO remove after https://github.com/zhaofengli/colmena/pull/228 is merged
(colmena.overrideAttrs (final: prev: {
nativeBuildInputs = prev.nativeBuildInputs ++ [pkgs.makeBinaryWrapper];
postInstall =
prev.postInstall
+ ''
wrapProgram $out/bin/colmena \
--prefix PATH ":" "${pkgs.lib.makeBinPath [pkgs.nixVersions.nix_2_18]}"
'';
}))
git-agecrypt
inputs.nvfetcher.packages.${pkgs.system}.default
];
name = "dots";
};
packages = import ./pkgs {
inherit pkgs;
};
formatter = pkgs.alejandra;
# formatter = pkgs.nixfmt-rfc-style;
};
};
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
flake-parts.url = "github:hercules-ci/flake-parts";
hardware.url = "github:nixos/nixos-hardware";
home-manager.url = "github:nix-community/home-manager";
nvim-nix = {
url = "github:xunuwu/nvim-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
stylix.url = "github:danth/stylix";
nur.url = "github:nix-community/NUR";
sops-nix.url = "github:Mic92/sops-nix";
nix-index-database.url = "github:Mic92/nix-index-database";
nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions";
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
nvfetcher.url = "github:berberman/nvfetcher";
microvm.url = "github:astro/microvm.nix";
vpn-confinement.url = "github:Maroka-chan/VPN-Confinement";
sobercookie.url = "github:xunuwu/sobercookie";
umu = {
url = "github:Open-Wine-Components/umu-launcher/?dir=packaging\/nix&submodules=1";
inputs.nixpkgs.follows = "nixpkgs";
};
haumea = {
url = "github:nix-community/haumea";
inputs.nixpkgs.follows = "nixpkgs";
};
nix-gaming = {
url = "github:fufexan/nix-gaming";
inputs.nixpkgs.follows = "nixpkgs";
};
## deduplication
flake-parts.inputs.nixpkgs-lib.follows = "nixpkgs";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
sops-nix.inputs = {
nixpkgs.follows = "nixpkgs";
nixpkgs-stable.follows = "nixpkgs";
};
nix-index-database.inputs.nixpkgs.follows = "nixpkgs";
nix-vscode-extensions.inputs.nixpkgs.follows = "nixpkgs";
nixos-wsl.inputs.nixpkgs.follows = "nixpkgs";
nvfetcher.inputs.nixpkgs.follows = "nixpkgs";
microvm.inputs.nixpkgs.follows = "nixpkgs";
};
}