diff --git a/flake.lock b/flake.lock index ce84011..1e6bb19 100644 --- a/flake.lock +++ b/flake.lock @@ -5,11 +5,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1769164550, - "narHash": "sha256-AxLb3L4j148v4Cj6ju5E9wsVdcHULuoI8il7+H5t6cs=", + "lastModified": 1770388745, + "narHash": "sha256-tmAONUMNHnlkozNcMR1kZJ/68OGea5wS56vl6vaUS5U=", "owner": "catppuccin", "repo": "nix", - "rev": "deb2a5a54cf9e05ddf60aeeb933f60ad2fac20e1", + "rev": "5e9efb97caeffea3bf248023b6d8b68e63b839b9", "type": "github" }, "original": { @@ -62,11 +62,11 @@ ] }, "locked": { - "lastModified": 1769289524, - "narHash": "sha256-6Cwtvzrw79cOk1lCzN2aKSVrpgSOSQoYhyMmhXXZjTA=", + "lastModified": 1770491427, + "narHash": "sha256-8b+0vixdqGnIIcgsPhjdX7EGPdzcVQqYxF+ujjex654=", "owner": "nix-community", "repo": "home-manager", - "rev": "2539eba97a6df237d75617c25cd2dbef92df3d5b", + "rev": "cbd8a72e5fe6af19d40e2741dc440d9227836860", "type": "github" }, "original": { @@ -78,11 +78,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1769018530, - "narHash": "sha256-MJ27Cy2NtBEV5tsK+YraYr2g851f3Fl1LpNHDzDX15c=", + "lastModified": 1770197578, + "narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "88d3861acdd3d2f0e361767018218e51810df8a1", + "rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2", "type": "github" }, "original": { @@ -109,11 +109,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1769170682, - "narHash": "sha256-oMmN1lVQU0F0W2k6OI3bgdzp2YOHWYUAw79qzDSjenU=", + "lastModified": 1770197578, + "narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=", "owner": "nixos", "repo": "nixpkgs", - "rev": "c5296fdd05cfa2c187990dd909864da9658df755", + "rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 6d0bb38..f3ffb2d 100644 --- a/flake.nix +++ b/flake.nix @@ -12,14 +12,20 @@ }; outputs = inputs: let - args = { inherit inputs; } // import ./lib/options.nix; pkgs = import inputs.nixpkgs { system = "x86_64-linux"; overlays = [ inputs.gl.overlay ]; - config.allowUnfree = true; + config = { + allowUnfree = true; + permittedInsecurePackages = [ "ventoy-qt5-1.1.10" ]; + }; }; + args = { + inherit inputs; + } // import ./lib/options.nix; - nixosConfigForHost = { host }: pkgs.lib.nixosSystem { + nixosConfigForHost = host: inputs.nixpkgs.lib.nixosSystem { + inherit pkgs; specialArgs = args; modules = [ ./hosts/${host}/config.nix @@ -30,6 +36,7 @@ extraSpecialArgs = args; backupFileExtension = ".hm-backup"; users.${args.username} = import ./hosts/${host}/home.nix; + sharedModules = [ inputs.ctp.homeModules.catppuccin ]; }; } ]; diff --git a/hosts/thinkpad/config.nix b/hosts/thinkpad/config.nix index ead13f8..4bc99fa 100644 --- a/hosts/thinkpad/config.nix +++ b/hosts/thinkpad/config.nix @@ -1,9 +1,9 @@ { ... }: { imports = [ ../../modules/scans/thinkpad.nix - ../../modules/hardware/thinkpad.nix - ../../modules/system/default.nix + + ../../modules/system ../../modules/system/user.nix ]; } diff --git a/hosts/thinkpad/home.nix b/hosts/thinkpad/home.nix index 49afe3d..380ad28 100644 --- a/hosts/thinkpad/home.nix +++ b/hosts/thinkpad/home.nix @@ -1,3 +1,6 @@ { ... }: { - + imports = [ + ../../modules/home + ../../modules/home/desktop.nix + ]; } \ No newline at end of file diff --git a/modules/home/core/apps.nix b/modules/home/core/apps.nix index f5f2acf..b0e3d46 100644 --- a/modules/home/core/apps.nix +++ b/modules/home/core/apps.nix @@ -1,4 +1,6 @@ { pkgs, ... }: { + nixpkgs.config.allowUnfree = true; + home = { sessionVariables = { EDITOR = "nvim"; diff --git a/modules/home/core/zsh.nix b/modules/home/core/zsh.nix index 52c5a0b..1725349 100644 --- a/modules/home/core/zsh.nix +++ b/modules/home/core/zsh.nix @@ -1,4 +1,4 @@ -{ hostname, flake-path, mc, ... }: { +{ hostname, flake-path, ... }: { programs = { pay-respects = { enable = true; @@ -41,19 +41,19 @@ "hm-sw" = "home-manager switch -b bak-hm --flake"; "nix-sw" = "sudo nixos-rebuild switch --flake"; "nix-hw-conf" = "nixos-generate-config --show-hardware-config"; + "nixos-diff" = "nix build .#nixosConfigurations.$(hostname).config.system.build.toplevel -o /tmp/nix-flake-diff && nvd diff /run/current-system /tmp/nix-flake-diff"; "cd-conf" = "cd ${flake-path}"; "code-conf" = "zeditor ${flake-path}"; "mkdistro" = "distrobox create -Y -i"; "mkdistro-arch" = "mkdistro archlinux -n arch"; "mkdistro-deb" = "mkdistro debian -n deb"; - "win11-compose" = "docker compose --file ~/.config/winapps/compose.yaml"; "wm-ctl" = "hyprctl --instance 0"; "wm-lock" = "wm-ctl dispatch exec loginctl lock-session && notify-send ${hostname} 'Manual lock triggered'"; "wm-dpms" = "wm-ctl dispatch dpms"; "git-author-setup" = "git config user.name $(gh api -H \"Accept: application/vnd.github+json\" -H \"X-GitHub-Api-Version: 2022-11-28\" /user | jq -r .login) && git config user.email $(gh api -H \"Accept: application/vnd.github+json\" -H \"X-GitHub-Api-Version: 2022-11-28\" /user/emails | jq -r \".[1].email\")"; - "mcl" = "portablemc start ${mc.version} -l ${mc.email}"; + "mcl" = "portablemc start -l $(cat .minecraft/portablemc-launch-params.json | jq .email) $(cat .minecraft/portablemc-launch-params.json | jq .version)"; "mc" = "ferium upgrade; mcl"; "please" = "SUDO_PROMPT=\"What is the magic word? \" sudo"; @@ -71,4 +71,4 @@ }; }; }; -} \ No newline at end of file +} diff --git a/modules/home/default.nix b/modules/home/default.nix index 40b8e02..f0cd6cd 100644 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -6,7 +6,6 @@ ./core/xdg.nix ./core/cli.nix ./core/zsh.nix - ./desktop.nix ]; home = { diff --git a/modules/system/default.nix b/modules/system/default.nix index 2d1474a..75f35a1 100644 --- a/modules/system/default.nix +++ b/modules/system/default.nix @@ -6,7 +6,6 @@ ./core/network.nix ./core/kernel.nix ./core/shell.nix - ./core/user.nix ./misc/programs.nix ./misc/graphics.nix ./desktop.nix diff --git a/modules/system/misc/nix-conf.nix b/modules/system/misc/nix-conf.nix index 5617350..9416619 100644 --- a/modules/system/misc/nix-conf.nix +++ b/modules/system/misc/nix-conf.nix @@ -1,5 +1,4 @@ { ... }: { - nixpkgs.config.allowUnfree = true; nix = { settings = { experimental-features = [ "nix-command" "flakes" ]; diff --git a/modules/system/misc/utilities.nix b/modules/system/misc/utilities.nix index 796de96..bb8dd55 100644 --- a/modules/system/misc/utilities.nix +++ b/modules/system/misc/utilities.nix @@ -1,8 +1,4 @@ { pkgs, ... }: { - nixpkgs.config.permittedInsecurePackages = [ - "ventoy-qt5-1.1.10" - ]; - environment.systemPackages = with pkgs; [ baobab file-roller @@ -59,6 +55,7 @@ nixd nil nh + nvd git ]; }