Compare commits

...

4 commits

7 changed files with 81 additions and 75 deletions

View file

@ -46,5 +46,7 @@
}; };
programs.nix-ld.enable = true; programs.nix-ld.enable = true;
environment.systemPackages = with pkgs; [ nvd ]; environment.systemPackages = with pkgs; [
nvd
];
} }

View file

@ -21,19 +21,19 @@
"ghostty": { "ghostty": {
"inputs": { "inputs": {
"nixpkgs-stable": [ "nixpkgs-stable": [
"nixpkgs" "nixpkgs-stable"
], ],
"nixpkgs-unstable": [ "nixpkgs-unstable": [
"nixpkgs" "nixpkgs-unstable"
], ],
"zig": "zig" "zig": "zig"
}, },
"locked": { "locked": {
"lastModified": 1728604055, "lastModified": 1729220096,
"narHash": "sha256-qFzvnwoWhGob+Huh3RlCxC+j16uF0LQKKV4dJxY4nDQ=", "narHash": "sha256-4erPSUsLVTTbdAXAjKfl7FpVxohmDSL0zWfewff7jcc=",
"ref": "refs/heads/main", "ref": "refs/heads/main",
"rev": "c26d1cb28eb5491e05ccbcff075a0eedd09ebaaa", "rev": "913c4b5801b0d3881eabbe93dec5a2c40fefe65f",
"revCount": 7679, "revCount": 7730,
"type": "git", "type": "git",
"url": "ssh://git@github.com/ghostty-org/ghostty" "url": "ssh://git@github.com/ghostty-org/ghostty"
}, },
@ -60,15 +60,15 @@
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs-unstable"
] ]
}, },
"locked": { "locked": {
"lastModified": 1728726232, "lastModified": 1729174520,
"narHash": "sha256-8ZWr1HpciQsrFjvPMvZl0W+b0dilZOqXPoKa2Ux36bc=", "narHash": "sha256-QxCAdgQdeIOaCiE0Sr23s9lD0+T1b/wuz5pSiGwNrCQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d57112db877f07387ce7104b5ac346ede556d2d7", "rev": "e78cbb20276f09c1802e62d2f77fc93ec32da268",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -77,13 +77,29 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs": { "nixpkgs-stable": {
"locked": { "locked": {
"lastModified": 1728492678, "lastModified": 1729044727,
"narHash": "sha256-9UTxR8eukdg+XZeHgxW5hQA9fIKHsKCdOIUycTryeVw=", "narHash": "sha256-GKJjtPY+SXfLF/yTN7M2cAnQB6RERFKnQhD8UvPSf3M=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "5633bcff0c6162b9e4b5f1264264611e950c8ec7", "rev": "dc2e0028d274394f73653c7c90cc63edbb696be1",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-24.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1728888510,
"narHash": "sha256-nsNdSldaAyu6PE3YUA+YQLqUDJh+gRbBooMMekZJwvI=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "a3c0b3b21515f74fd2665903d4ce6bc4dc81c77c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -98,7 +114,8 @@
"ghostty": "ghostty", "ghostty": "ghostty",
"ghostty-hm": "ghostty-hm", "ghostty-hm": "ghostty-hm",
"home-manager": "home-manager", "home-manager": "home-manager",
"nixpkgs": "nixpkgs" "nixpkgs-stable": "nixpkgs-stable",
"nixpkgs-unstable": "nixpkgs-unstable"
} }
}, },
"systems": { "systems": {

View file

@ -2,94 +2,65 @@
description = "NixOS configuration"; description = "NixOS configuration";
inputs = { inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-24.05";
home-manager.url = "github:nix-community/home-manager"; home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs"; home-manager.inputs.nixpkgs.follows = "nixpkgs-unstable";
ghostty = { ghostty = {
url = "git+ssh://git@github.com/ghostty-org/ghostty"; url = "git+ssh://git@github.com/ghostty-org/ghostty";
inputs = { inputs = {
nixpkgs-stable.follows = "nixpkgs"; nixpkgs-stable.follows = "nixpkgs-stable";
nixpkgs-unstable.follows = "nixpkgs"; nixpkgs-unstable.follows = "nixpkgs-unstable";
}; };
}; };
ghostty-hm.url = "github:clo4/ghostty-hm-module"; ghostty-hm.url = "github:clo4/ghostty-hm-module";
}; };
outputs = outputs =
{ inputs@{
self, self,
nixpkgs, nixpkgs-unstable,
ghostty,
ghostty-hm, ghostty-hm,
home-manager, home-manager,
... ...
}@inputs: }:
let let
inherit (self) outputs; inherit (self) outputs;
system = "x86_64-linux";
pkgs = nixpkgs-unstable.legacyPackages.${system};
mkHost =
modules:
nixpkgs-unstable.lib.nixosSystem {
specialArgs = {
inherit inputs outputs;
};
modules = [ ./common ] ++ modules;
};
mkHome = mkHome =
modules: modules:
home-manager.lib.homeManagerConfiguration { home-manager.lib.homeManagerConfiguration {
inherit pkgs;
extraSpecialArgs = {
inherit inputs outputs;
};
modules = [ modules = [
ghostty-hm.homeModules.default ghostty-hm.homeModules.default
./home/common ./home/common
] ++ modules; ] ++ modules;
pkgs = nixpkgs.legacyPackages.x86_64-linux;
extraSpecialArgs = {
inherit inputs outputs;
};
}; };
mkHost =
modules:
nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs outputs;
};
system = "x86_64-linux";
modules = [ ./common ] ++ modules;
};
supportedSystems = [
"x86_64-linux"
"aarch64-linux"
];
forEachSystem =
f:
builtins.listToAttrs (
map (system: {
name = system;
value = f system;
}) supportedSystems
);
systemBits = forEachSystem (system: rec {
inherit system;
pkgs = import nixpkgs {
localSystem = system;
overlays = [ ];
};
});
forEachSystem' = f: forEachSystem (system: (f systemBits.${system}));
inherit (nixpkgs) lib;
in in
{ {
overlays = import ./overlays { inherit inputs outputs; }; overlays = import ./overlays { inherit inputs outputs; };
devShells = forEachSystem' ( devShell.${system} = pkgs.mkShell {
{ system, pkgs, ... }: packages = with pkgs; [
{ just
default = pkgs.mkShell { packages = [ ]; }; nh
} ];
);
homeConfigurations = {
"dln@dinky" = mkHome [ ./home/dln/dinky.nix ];
"dln@nemo" = mkHome [ ./home/dln/nemo.nix ];
"dln@pearl" = mkHome [ ./home/dln/pearl.nix ];
"lsjostro@nemo" = mkHome [ ./home/lsjostro/nemo.nix ];
}; };
nixosConfigurations = { nixosConfigurations = {
@ -97,5 +68,12 @@
nemo = mkHost [ ./hosts/nemo ]; nemo = mkHost [ ./hosts/nemo ];
pearl = mkHost [ ./hosts/pearl ]; pearl = mkHost [ ./hosts/pearl ];
}; };
homeConfigurations = {
"dln@dinky" = mkHome [ ./home/dln/dinky.nix ];
"dln@nemo" = mkHome [ ./home/dln/nemo.nix ];
"dln@pearl" = mkHome [ ./home/dln/pearl.nix ];
"lsjostro@nemo" = mkHome [ ./home/lsjostro/nemo.nix ];
};
}; };
} }

View file

@ -14,6 +14,7 @@
ldns ldns
minio-client minio-client
nil nil
nix-output-monitor
nixd nixd
nixfmt-rfc-style nixfmt-rfc-style
nodejs_22 nodejs_22

View file

@ -1,4 +1,8 @@
{ outputs, ... }: {
pkgs,
outputs,
...
}:
{ {
nixpkgs = { nixpkgs = {
config.allowUnfree = true; config.allowUnfree = true;

View file

@ -24,7 +24,7 @@
}; };
}; };
home.packages = with pkgs; [ calibre ]; home.packages = with pkgs; [ stable.calibre ];
programs.gpg.enable = true; programs.gpg.enable = true;

View file

@ -13,6 +13,10 @@
}; };
unstable-packages = final: _prev: { unstable-packages = final: _prev: {
stable = import inputs.nixpkgs-stable {
system = final.system;
config.allowUnfree = true;
};
unstable = import inputs.nixpkgs-unstable { unstable = import inputs.nixpkgs-unstable {
system = final.system; system = final.system;
config.allowUnfree = true; config.allowUnfree = true;