use NUR as flake input

closes #12
This commit is contained in:
Pim Kunis 2023-10-16 17:45:15 +02:00
parent db10ca11f3
commit fd51e1f396
5 changed files with 28 additions and 26 deletions

View file

@ -19,14 +19,14 @@
}; };
}; };
outputs = { nixpkgs, home-manager, homeage, agenix, ... }: { outputs = { nixpkgs, home-manager, homeage, agenix, nur, ... }: {
nixosConfigurations = { nixosConfigurations.pim = nixpkgs.lib.nixosSystem {
pim = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./configuration.nix ./configuration.nix
agenix.nixosModules.default agenix.nixosModules.default
home-manager.nixosModules.home-manager { home-manager.nixosModules.home-manager {
home-manager.extraSpecialArgs = { inherit nur; };
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true; home-manager.useUserPackages = true;
home-manager.users.pim = { home-manager.users.pim = {
@ -39,5 +39,4 @@
]; ];
}; };
}; };
};
} }

View file

@ -1,10 +1,13 @@
{ pkgs, config, ... }: { pkgs, nur, ... }:
let
nur-no-pkgs = import (nur) { inherit pkgs; nurpkgs = pkgs; };
in
{ {
imports = [ imports = [
./bash ./bash
./neovim ./neovim
./firefox (import ./firefox nur-no-pkgs) # TODO: bit of a hack, but better than before
./ssh ./ssh
./syncthing ./syncthing
./alacritty ./alacritty

View file

@ -1,7 +1,7 @@
nurpkgs:
{ pkgs, lib, ... }@args: { pkgs, lib, ... }@args:
let let
nurpkgs = import (builtins.fetchTarball {url = "https://github.com/nix-community/NUR/archive/master.tar.gz"; sha256 = "1gb3wkmyl6xbs4kval2ml48nlil39853dj62rxfrlk9i2nky2ly4"; }) { inherit pkgs; };
firefoxAddons = import ./addons.nix (args // { inherit nurpkgs; }); firefoxAddons = import ./addons.nix (args // { inherit nurpkgs; });
firefoxSettings = { firefoxSettings = {
"browser.aboutConfig.showWarning" = false; "browser.aboutConfig.showWarning" = false;

View file

@ -1,3 +1,3 @@
#!/usr/bin/env bash #!/usr/bin/env bash
sudo nixos-rebuild switch --flake ./#pim --impure sudo nixos-rebuild switch --flake ./#pim