diff --git a/home/darwin/color-pickers/module.nix b/home/darwin/color-pickers/module.nix index 3f1bf16..51f0d85 100644 --- a/home/darwin/color-pickers/module.nix +++ b/home/darwin/color-pickers/module.nix @@ -11,7 +11,7 @@ config = { assertions = [{ - assertion = config.home.colorPickers.enable && (config.home.colorPickers != []) && !pkgs.stdenv.hostPlatform.isDarwin; + assertion = config.home.colorPickers.enable && (config.home.colorPickers != [ ]) && !pkgs.stdenv.hostPlatform.isDarwin; message = "Must use Darwin to install color pickers."; }]; diff --git a/home/darwin/desktop-standalone-packages.nix b/home/darwin/desktop-standalone-packages.nix index 981a123..77ba8cc 100644 --- a/home/darwin/desktop-standalone-packages.nix +++ b/home/darwin/desktop-standalone-packages.nix @@ -1,5 +1,5 @@ -{ pkgs, ... }: -{ +{ pkgs, lib, config, ... }: +lib.mkIf config.local.system.darwin { home.packages = [ pkgs.iterm2 ]; diff --git a/home/darwin/git.nix b/home/darwin/git.nix index 8ebccdd..dc6eccf 100644 --- a/home/darwin/git.nix +++ b/home/darwin/git.nix @@ -1,4 +1,5 @@ -{ +{ lib, config, ... }: +lib.mkIf config.local.system.darwin { programs.git = { ignores = [ ".DS_Store" # https://en.wikipedia.org/wiki/.DS_Store diff --git a/home/linux/blueman.nix b/home/linux/blueman.nix index 9f04745..d903ae3 100644 --- a/home/linux/blueman.nix +++ b/home/linux/blueman.nix @@ -1,7 +1,7 @@ { lib, config, ... }: { services.blueman-applet = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; }; dconf.settings = { diff --git a/home/linux/desktop-standalone-packages.nix b/home/linux/desktop-standalone-packages.nix index 8445240..6fce62a 100644 --- a/home/linux/desktop-standalone-packages.nix +++ b/home/linux/desktop-standalone-packages.nix @@ -3,7 +3,7 @@ let firejailWrappers = tomolib.firejailWrappers { inherit pkgs; }; in { - home.packages = lib.optionals config.local.eagerSetup.enableGraphicalApps [ + home.packages = lib.optionals (config.local.system.linux && config.local.eagerSetup.enableGraphicalApps) [ pkgs.lxqt.qps pkgs.zotero tomopkgs.${pkgs.system}.crosshair-dot diff --git a/home/linux/dunst.nix b/home/linux/dunst.nix index b928be3..4752888 100644 --- a/home/linux/dunst.nix +++ b/home/linux/dunst.nix @@ -1,7 +1,7 @@ { config, ... }: { services.dunst = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; }; stylix.targets.dunst.enable = true; diff --git a/home/linux/fcitx5/default.nix b/home/linux/fcitx5/default.nix index c4cd018..b411fd5 100644 --- a/home/linux/fcitx5/default.nix +++ b/home/linux/fcitx5/default.nix @@ -1,5 +1,5 @@ { pkgs, lib, config, ... }: -lib.mkIf config.local.eagerSetup.enableGraphicalApps { +lib.mkIf (config.local.system.linux && config.local.eagerSetup.enableGraphicalApps) { i18n.inputMethod.enabled = "fcitx5"; i18n.inputMethod.fcitx5.addons = with pkgs; [ fcitx5-mozc diff --git a/home/linux/fun.nix b/home/linux/fun.nix index 311636e..677e96b 100644 --- a/home/linux/fun.nix +++ b/home/linux/fun.nix @@ -1,6 +1,6 @@ { pkgs, lib, config, ... }: { - home.packages = lib.optionals config.local.eagerSetup.enableGames [ + home.packages = lib.optionals (config.local.system.linux && config.local.eagerSetup.enableGames) [ pkgs.prismlauncher pkgs.lutris # Launcher for Windows-only games ]; diff --git a/home/linux/gnome-keyring.nix b/home/linux/gnome-keyring.nix index 95055ba..b1f98d6 100644 --- a/home/linux/gnome-keyring.nix +++ b/home/linux/gnome-keyring.nix @@ -1,6 +1,6 @@ { config, ... }: { services.gnome-keyring = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; }; } diff --git a/home/linux/gnome-terminal.nix b/home/linux/gnome-terminal.nix index bbb4c7b..10955ce 100644 --- a/home/linux/gnome-terminal.nix +++ b/home/linux/gnome-terminal.nix @@ -1,7 +1,7 @@ { vars, config, ... }: { programs.gnome-terminal = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; profile."b1dcc9dd-5262-4d8d-a863-c897e6d979b9" = { default = true; loginShell = true; diff --git a/home/linux/gtk.nix b/home/linux/gtk.nix index 133a756..dc3258f 100644 --- a/home/linux/gtk.nix +++ b/home/linux/gtk.nix @@ -1,7 +1,7 @@ { pkgs, config, ... }: { gtk = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; # cursorTheme.package = pkgs.vanilla-dmz; # cursorTheme.name = "Vanilla-DMZ"; # cursorTheme.size = 23; diff --git a/home/linux/home-manager.nix b/home/linux/home-manager.nix index 1ebca5a..0349fe7 100644 --- a/home/linux/home-manager.nix +++ b/home/linux/home-manager.nix @@ -1,4 +1,5 @@ -{ +{ config, lib, ... }: +lib.mkIf config.local.system.linux { home.username = "me"; home.homeDirectory = "/home/me"; } diff --git a/home/linux/i3/default.nix b/home/linux/i3/default.nix index 29fe73d..ab76c44 100644 --- a/home/linux/i3/default.nix +++ b/home/linux/i3/default.nix @@ -24,7 +24,7 @@ }; # For cleanliness, this contains any packages that are exclusively used in this configuration. - home.packages = lib.optionals config.local.eagerSetup.enableGraphicalApps (with pkgs; [ + home.packages = lib.optionals (config.local.system.linux && config.local.eagerSetup.enableGraphicalApps) (with pkgs; [ xss-lock brightnessctl playerctl diff --git a/home/linux/i3status-rust/default.nix b/home/linux/i3status-rust/default.nix index 4ad1250..ecd4c82 100644 --- a/home/linux/i3status-rust/default.nix +++ b/home/linux/i3status-rust/default.nix @@ -1,5 +1,5 @@ -{ pkgs, ... }: -{ +{ pkgs, lib, config, ... }: +lib.mkIf (config.local.system.linux && config.local.eagerSetup.enableGraphicalApps) { xdg.configFile."i3status-rust/config.toml".source = ./config.toml; home.packages = [ diff --git a/home/linux/i3status/default.nix b/home/linux/i3status/default.nix index c9362be..d5a0bcb 100644 --- a/home/linux/i3status/default.nix +++ b/home/linux/i3status/default.nix @@ -1,3 +1,4 @@ -{ +{ config, lib, ... }: +lib.mkIf config.local.system.linux { xdg.configFile."i3status".source = ./.; } diff --git a/home/linux/kdeconnect.nix b/home/linux/kdeconnect.nix index 3856106..6623815 100644 --- a/home/linux/kdeconnect.nix +++ b/home/linux/kdeconnect.nix @@ -1,6 +1,6 @@ { config, ... }: { services.kdeconnect = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; }; } diff --git a/home/linux/kitty/default.nix b/home/linux/kitty/default.nix index a54fa20..dfe59ca 100644 --- a/home/linux/kitty/default.nix +++ b/home/linux/kitty/default.nix @@ -1,3 +1,4 @@ -{ +{ lib, config, ... }: +lib.mkIf config.local.system.linux { xdg.configFile."kitty".source = ./.; } diff --git a/home/linux/network-manager-applet.nix b/home/linux/network-manager-applet.nix index b77995e..efea8ff 100644 --- a/home/linux/network-manager-applet.nix +++ b/home/linux/network-manager-applet.nix @@ -1,6 +1,6 @@ { config, ... }: { services.network-manager-applet = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; }; } diff --git a/home/linux/volnoti.nix b/home/linux/volnoti.nix index cd75cde..d1b2f44 100644 --- a/home/linux/volnoti.nix +++ b/home/linux/volnoti.nix @@ -1,7 +1,7 @@ { pkgs, tomopkgs, config, ... }: { services.volnoti = { - enable = config.local.eagerSetup.enableGraphicalApps; + enable = config.local.system.linux && config.local.eagerSetup.enableGraphicalApps; package = tomopkgs.${pkgs.system}.volnoti; }; } diff --git a/home/linux/xdg.nix b/home/linux/xdg.nix index 4f7da2b..fec96c4 100644 --- a/home/linux/xdg.nix +++ b/home/linux/xdg.nix @@ -1,12 +1,12 @@ # NOTE: DO NOT INCLUDE XDG.CONFIGFILE SETTINGS HERE :) -{ pkgs, config, ... }: +{ pkgs, lib, config, ... }: { xdg = { userDirs = { - enable = true; + enable = config.local.system.linux; }; mimeApps = { - enable = true; + enable = config.local.system.linux; defaultApplications = { # TODO: Split into modules and conditionally enable these rules if the application is enabled "x-scheme-handler/https" = "/etc/profiles/per-user/me/share/applications/librewolf.desktop"; @@ -17,6 +17,8 @@ "x-scheme-handler/feed" = "${pkgs.liferea}/share/applications/net.sourceforge.liferea.desktop"; }; }; - configFile."user-dirs.locale".text = "en_US"; + configFile."user-dirs.locale" = lib.mkIf config.local.system.linux { + text = "en_US"; + }; }; }