begin to create checks to make nixos modules home-manager independent

This commit is contained in:
greyweather committed 2026-08-28 15:19:06 +01:00
1 parent 22d431e271
commit 2ca8b405e8
17 files changed
+100 -210

No files matched your search

+16
View File
@@ -6,5 +6,21 @@
{ {
"command": "workbench.action.files.newFile", "command": "workbench.action.files.newFile",
"key": "alt+enter" "key": "alt+enter"
},
{
"key": "alt+right",
"command": "workbench.action.nextEditor"
},
{
"key": "ctrl+pagedown",
"command": "-workbench.action.nextEditor"
},
{
"key": "alt+left",
"command": "workbench.action.previousEditor"
},
{
"key": "ctrl+pageup",
"command": "-workbench.action.previousEditor"
} }
] ]
@@ -4,7 +4,7 @@
"authenticated": false, "authenticated": false,
"settingsSync": false, "settingsSync": false,
"url": "https://cloud.equicord.org/", "url": "https://cloud.equicord.org/",
"settingsSyncVersion": 1787543449308 "settingsSyncVersion": 1787926226537
}, },
"enableOnlineThemes": true, "enableOnlineThemes": true,
"enabledThemeLinks": [ "enabledThemeLinks": [
Generated
+9 -178
View File
@@ -106,22 +106,6 @@
"type": "github" "type": "github"
} }
}, },
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "NixOS",
"repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
@@ -141,24 +125,6 @@
} }
}, },
"flake-parts_2": { "flake-parts_2": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib_2"
},
"locked": {
"lastModified": 1787559586,
"narHash": "sha256-onL0VLf9vPllmT0H/OlURIU5r5t5WIEl7t4tVNKT0Nw=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "9d0d87172c374f89da73c1cfe6d81ae62feac1f1",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_3": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
"stylix", "stylix",
@@ -269,55 +235,18 @@
"type": "github" "type": "github"
} }
}, },
"nix-cachyos-kernel": {
"inputs": {
"flake-compat": "flake-compat",
"flake-parts": "flake-parts_2",
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1787594581,
"narHash": "sha256-C0Ckqq9K/XMIWKW/OFeIkKipMXc6Qc3eFMiY4w7Iv8o=",
"owner": "xddxdd",
"repo": "nix-cachyos-kernel",
"rev": "be42f230afd6789046dc99c4479236d4061fe7e1",
"type": "github"
},
"original": {
"owner": "xddxdd",
"ref": "release",
"repo": "nix-cachyos-kernel",
"type": "github"
}
},
"nix-flatpak": {
"locked": {
"lastModified": 1767983141,
"narHash": "sha256-7ZCulYUD9RmJIDULTRkGLSW1faMpDlPKcbWJLYHoXcs=",
"owner": "gmodena",
"repo": "nix-flatpak",
"rev": "440818969ac2cbd77bfe025e884d0aa528991374",
"type": "github"
},
"original": {
"owner": "gmodena",
"ref": "latest",
"repo": "nix-flatpak",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1787574585, "lastModified": 1787498568,
"narHash": "sha256-lYyM+zbWl1jCJ5xSxPzCkPtxO3OXMst8+QfboXRQCcs=", "narHash": "sha256-9i/VTdusq/+NM/tz+J1Re+ojkMB8MBf0QshnYfzHz30=",
"owner": "NixOS", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "09cf6aa915e6e042f74607067dffa237084ff53e", "rev": "56c02bc00adcf003215cc4bd996d6efaf4cff188",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "nixos",
"ref": "nixos-unstable-small", "ref": "nixos-unstable",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
@@ -337,53 +266,6 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs-lib_2": {
"locked": {
"lastModified": 1785031560,
"narHash": "sha256-OmshNvn2vupOFpYinLUu+1Dnpu4n7Q5N3ggGVNHpkUI=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "0e79af5e3d4dcfcd676ab5ba3f95d2e3352e078c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixpkgs.lib",
"type": "github"
}
},
"nixpkgs-mesa-overlay": {
"locked": {
"lastModified": 1770837850,
"narHash": "sha256-kHUN55l4Nqa1ODhItVDBOpKcdP1wQJM+STy7H+7/ARQ=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "e4f9df8a27c2b4871c665368e65bdb6852dd93e6",
"type": "github"
},
"original": {
"owner": "nixos",
"repo": "nixpkgs",
"rev": "e4f9df8a27c2b4871c665368e65bdb6852dd93e6",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1787498568,
"narHash": "sha256-9i/VTdusq/+NM/tz+J1Re+ojkMB8MBf0QshnYfzHz30=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "56c02bc00adcf003215cc4bd996d6efaf4cff188",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"noctalia": { "noctalia": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -429,29 +311,6 @@
"type": "github" "type": "github"
} }
}, },
"plasma-manager": {
"inputs": {
"home-manager": [
"home-manager"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1785762349,
"narHash": "sha256-jZhZkzAwc7f3exzcTDJWP2WCAchCv0iNC3UF/QsahdQ=",
"owner": "nix-community",
"repo": "plasma-manager",
"rev": "a19a2a029fa180911bd89c554dca1616e10f4c1d",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "plasma-manager",
"type": "github"
}
},
"root": { "root": {
"inputs": { "inputs": {
"firefox-addons": "firefox-addons", "firefox-addons": "firefox-addons",
@@ -459,15 +318,10 @@
"home-manager": "home-manager", "home-manager": "home-manager",
"import-tree": "import-tree", "import-tree": "import-tree",
"nh": "nh", "nh": "nh",
"nix-cachyos-kernel": "nix-cachyos-kernel", "nixpkgs": "nixpkgs",
"nix-flatpak": "nix-flatpak",
"nixpkgs": "nixpkgs_2",
"nixpkgs-mesa-overlay": "nixpkgs-mesa-overlay",
"noctalia": "noctalia", "noctalia": "noctalia",
"plasma-manager": "plasma-manager",
"spicetify": "spicetify", "spicetify": "spicetify",
"stylix": "stylix", "stylix": "stylix"
"zen-browser": "zen-browser"
} }
}, },
"spicetify": { "spicetify": {
@@ -498,7 +352,7 @@
"base16-helix": "base16-helix", "base16-helix": "base16-helix",
"base16-vim": "base16-vim", "base16-vim": "base16-vim",
"firefox-gnome-theme": "firefox-gnome-theme", "firefox-gnome-theme": "firefox-gnome-theme",
"flake-parts": "flake-parts_3", "flake-parts": "flake-parts_2",
"gnome-shell": "gnome-shell", "gnome-shell": "gnome-shell",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
@@ -618,29 +472,6 @@
"repo": "base16-zed", "repo": "base16-zed",
"type": "github" "type": "github"
} }
},
"zen-browser": {
"inputs": {
"home-manager": [
"home-manager"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1787540616,
"narHash": "sha256-c+dIgStaq3qNaQxhAiiXY3upNTIdn7tCcqPnwsmKTmY=",
"owner": "0xc000022070",
"repo": "zen-browser-flake",
"rev": "51df7b8cbb0fcba14a9b159531ef48d0cd69dde9",
"type": "github"
},
"original": {
"owner": "0xc000022070",
"repo": "zen-browser-flake",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",
+9 -9
View File
@@ -8,7 +8,7 @@
import-tree.url = "github:vic/import-tree"; import-tree.url = "github:vic/import-tree";
nixpkgs-mesa-overlay.url = "github:nixos/nixpkgs/e4f9df8a27c2b4871c665368e65bdb6852dd93e6"; #nixpkgs-mesa-overlay.url = "github:nixos/nixpkgs/e4f9df8a27c2b4871c665368e65bdb6852dd93e6";
home-manager = { home-manager = {
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
@@ -25,22 +25,22 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
zen-browser = { /* zen-browser = {
url = "github:0xc000022070/zen-browser-flake"; url = "github:0xc000022070/zen-browser-flake";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
inputs.home-manager.follows = "home-manager"; inputs.home-manager.follows = "home-manager";
}; }; */
firefox-addons = { firefox-addons = {
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons"; url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
plasma-manager = { /* plasma-manager = {
url = "github:nix-community/plasma-manager"; url = "github:nix-community/plasma-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
inputs.home-manager.follows = "home-manager"; inputs.home-manager.follows = "home-manager";
}; }; */
noctalia = { noctalia = {
url = "github:noctalia-dev/noctalia"; url = "github:noctalia-dev/noctalia";
@@ -52,14 +52,14 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
/*nixos-millennium = { /* nixos-millennium = {
url = "git+https://git.greyweather.dev/greyweather/nixos-millennium"; url = "git+https://git.greyweather.dev/greyweather/nixos-millennium";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
};*/ }; */
nix-cachyos-kernel.url = "github:xddxdd/nix-cachyos-kernel/release"; #nix-cachyos-kernel.url = "github:xddxdd/nix-cachyos-kernel/release";
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest"; #nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest";
}; };
outputs = inputs@{ self, flake-parts, import-tree, ... }: flake-parts.lib.mkFlake { inherit inputs; } (import-tree ./modules); outputs = inputs@{ self, flake-parts, import-tree, ... }: flake-parts.lib.mkFlake { inherit inputs; } (import-tree ./modules);
+2 -2
View File
@@ -8,7 +8,7 @@
programs.noctalia.enable = true; programs.noctalia.enable = true;
home-manager.sharedModules = [ home-manager.sharedModules = [
{ ({ lib, config, ... }: {
home.activation = { home.activation = {
symlinkNoctaliaState = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript { symlinkNoctaliaState = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript {
target = ".local/state/noctalia/settings.toml"; target = ".local/state/noctalia/settings.toml";
@@ -24,7 +24,7 @@
xdg.configFile."noctalia/settings.toml".source = "${self}/dotfiles/${config.info.hostName}/noctalia/settings.toml"; xdg.configFile."noctalia/settings.toml".source = "${self}/dotfiles/${config.info.hostName}/noctalia/settings.toml";
xdg.configFile."noctalia/plugins".source = "${self}/dotfiles/${config.info.hostName}/noctalia/plugins"; xdg.configFile."noctalia/plugins".source = "${self}/dotfiles/${config.info.hostName}/noctalia/plugins";
} })
]; ];
}; };
}; };
+2 -2
View File
@@ -38,12 +38,12 @@
}; };
home-manager.sharedModules = [ home-manager.sharedModules = [
{ ({ lib, config, ... }: {
home.activation.symlinkNiriConfig = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript { home.activation.symlinkNiriConfig = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript {
target = ".config/niri/config.kdl"; target = ".config/niri/config.kdl";
source = "dotfiles/${config.info.hostName}/niri.kdl"; source = "dotfiles/${config.info.hostName}/niri.kdl";
}); });
} })
]; ];
}; };
}; };
@@ -1,4 +1,23 @@
{ inputs, self, ... }: { { inputs, self, ... }: {
flake.nixosModules.graphics = { pkgs, lib, config, ...}: {
options.features.applications.gui.equibop.enable = lib.mkEnableOption "equibop";
config = let
mkIfElse = with lib; p: yes: no: mkMerge [
(mkIf p yes)
(mkIf (!p) no)
];
in lib.mkIf (config.features.applications.gui.equibop.enable) (mkIfElse (config.features.nixos.home-manager.enable) {
home-manager.sharedModules = [
{
features.applications.gui.equibop.enable = lib.mkDefault true;
}
];
} {
environment.systemPackages = [ pkgs.equibop ];
});
};
flake.homeModules.graphics = { pkgs, lib, config, ... }: { flake.homeModules.graphics = { pkgs, lib, config, ... }: {
options.features.applications.gui.equibop.enable = lib.mkEnableOption "equibop"; options.features.applications.gui.equibop.enable = lib.mkEnableOption "equibop";
+14 -5
View File
@@ -2,11 +2,20 @@
flake.nixosModules.graphics = { pkgs, config, lib, ... }: { flake.nixosModules.graphics = { pkgs, config, lib, ... }: {
options.features.applications.gui.kitty.enable = lib.mkEnableOption "kitty"; options.features.applications.gui.kitty.enable = lib.mkEnableOption "kitty";
config.home-manager.sharedModules = lib.mkIf (config.features.applications.gui.kitty.enable) [ config = let
{ mkIfElse = with lib; p: yes: no: mkMerge [
features.applications.gui.kitty.enable = true; (mkIf p yes)
} (mkIf (!p) no)
]; ];
in lib.mkIf (config.features.applications.gui.kitty.enable) (mkIfElse (config.features.nixos.home-manager.enable) {
home-manager.sharedModules = [
{
features.applications.gui.kitty.enable = lib.mkDefault true;
}
];
} {
environment.systemPackages = [ pkgs.kitty ];
});
}; };
flake.homeModules.graphics = { pkgs, config, lib, ... }: { flake.homeModules.graphics = { pkgs, config, lib, ... }: {
+10 -6
View File
@@ -2,18 +2,22 @@
flake.nixosModules.graphics = { config, pkgs, lib, ... }: { flake.nixosModules.graphics = { config, pkgs, lib, ... }: {
options.features.applications.gui.vscode.enable = lib.mkEnableOption "vscode"; options.features.applications.gui.vscode.enable = lib.mkEnableOption "vscode";
config.home-manager.sharedModules = lib.mkIf (config.features.applications.gui.vscode.enable) [ config = {
{ environment.systemPackages = [ pkgs.vscode ];
features.applications.gui.vscode.enable = true;
} home-manager.sharedModules = lib.mkIf (config.features.applications.gui.vscode.enable) [
]; {
features.applications.gui.vscode.enable = lib.mkDefault true;
}
];
};
}; };
flake.homeModules.graphics = { config, pkgs, lib, ... }: { flake.homeModules.graphics = { config, pkgs, lib, ... }: {
options.features.applications.gui.vscode.enable = lib.mkEnableOption "vscode"; options.features.applications.gui.vscode.enable = lib.mkEnableOption "vscode";
config = lib.mkIf (config.features.applications.gui.vscode.enable) { config = lib.mkIf (config.features.applications.gui.vscode.enable) {
home.packages = [ pkgs.vscode ]; home.packages = lib.mkIf (config.info.isStandalone) [ pkgs.vscode ];
home.activation = { home.activation = {
linkVsCodeConfigSettings = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript { linkVsCodeConfigSettings = lib.hm.dag.entryAfter ["writeBoundary"] (config.helpers.mkSymlinkActivationScript {
+6
View File
@@ -81,5 +81,11 @@
enable = true; enable = true;
powerOnBoot = false; powerOnBoot = false;
}; };
home-manager.sharedModules = [
({ config, ... }: {
info.isStandalone = false;
})
];
}; };
} }
+4 -2
View File
@@ -1,12 +1,14 @@
{ inputs, self, ... }: { { inputs, self, ... }: {
flake.homeModules.global = { config, pkgs, ... }: { flake.homeModules.global = { lib, config, pkgs, ... }: {
nix.gc = { nix.gc = {
automatic = true; automatic = true;
persistent = true; persistent = true;
dates = "Sun 05:00"; dates = "Sun 05:00";
}; };
nixpkgs.config.allowUnfree = true; nixpkgs.config = lib.mkIf (config.info.isStandalone) {
allowUnfree = true;
};
home = { home = {
stateVersion = config.info.stateVersion; stateVersion = config.info.stateVersion;
+1 -1
View File
@@ -52,7 +52,7 @@
isStandalone = lib.mkOption { isStandalone = lib.mkOption {
type = lib.types.bool; type = lib.types.bool;
default = false; default = true;
}; };
}; };
+2 -1
View File
@@ -35,6 +35,7 @@
gui = { gui = {
kitty.enable = true; kitty.enable = true;
vscode.enable = true; vscode.enable = true;
equibop.enable = true;
}; };
extraPackages = with pkgs; [ extraPackages = with pkgs; [
@@ -97,7 +98,6 @@
}; };
gui = { gui = {
equibop.enable = true;
floorp.enable = true; floorp.enable = true;
remmina.enable = true; remmina.enable = true;
spotify = { spotify = {
@@ -116,6 +116,7 @@
signal-desktop signal-desktop
xarchiver xarchiver
kdePackages.filelight kdePackages.filelight
kdePackages.kate
loupe loupe
]; ];
}; };
+5 -3
View File
@@ -2,18 +2,20 @@
flake.homeConfigurations.takamaki = inputs.home-manager.lib.homeManagerConfiguration { flake.homeConfigurations.takamaki = inputs.home-manager.lib.homeManagerConfiguration {
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux; pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
modules = with self.homeModules; [ modules = with self.homeModules; [
global
graphics
takamaki takamaki
]; ];
}; };
flake.homeModules.takamaki = { pkgs, config, lib, ... }: { flake.homeModules.takamaki = { pkgs, config, lib, ... }: {
imports = with self.homeModules; [
global
graphics
];
info = { info = {
rootPath = "/home/grey/flake"; rootPath = "/home/grey/flake";
hostName = "takamaki"; hostName = "takamaki";
stateVersion = "26.11"; stateVersion = "26.11";
isStandalone = true;
}; };
features = { features = {