74 lines
1.8 KiB
Nix
74 lines
1.8 KiB
Nix
{
|
|
description = "My NixOS config flake";
|
|
outputs = inputs: let
|
|
inherit (inputs.nixpkgs) lib;
|
|
eachSystem = lib.genAttrs (import inputs.systems);
|
|
pkgsFor = inputs.nixpkgs.legacyPackages;
|
|
in {
|
|
nixosConfigurations = import ./hosts inputs;
|
|
|
|
formatter = eachSystem (system: pkgsFor.${system}.alejandra);
|
|
|
|
packages =
|
|
lib.mapAttrs (
|
|
_: pkgs: {
|
|
inherit
|
|
(import ./packages {
|
|
inherit inputs pkgs;
|
|
})
|
|
fish
|
|
helix
|
|
kakoune
|
|
;
|
|
}
|
|
)
|
|
pkgsFor;
|
|
|
|
apps = eachSystem (system: let
|
|
inherit (inputs.self.packages.${system}) fish helix;
|
|
in {
|
|
default = {
|
|
type = "app";
|
|
program = "${fish}/bin/fish";
|
|
};
|
|
helix = {
|
|
type = "app";
|
|
program = "${helix}/bin/hx";
|
|
};
|
|
});
|
|
|
|
templates = import ./templates;
|
|
};
|
|
inputs = {
|
|
# Unstable nixpkgs, using the new Lockable HTTP Tarball protocol
|
|
# https://github.com/NixOS/infra/pull/562.
|
|
nixpkgs.url = "https://channels.nixos.org/nixpkgs-unstable/nixexprs.tar.xz";
|
|
|
|
systems.url = "github:nix-systems/default-linux";
|
|
|
|
impermanence.url = "github:nix-community/impermanence";
|
|
|
|
watt = {
|
|
url = "github:notashelf/watt";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
# secure booting
|
|
lanzaboote = {
|
|
url = "github:nix-community/lanzaboote";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
# The things rust is making me do...
|
|
rust-overlay = {
|
|
url = "github:oxalica/rust-overlay";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
# DetNix is doing too well these days not to use it.
|
|
determinate = {
|
|
url = "github:determinatesystems/determinate";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
};
|
|
}
|