From 4dc5c2ffd5b5b367f86b18df216afb438d104649 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 1 Sep 2025 19:18:06 +0200 Subject: [PATCH 1/5] reformat of files --- machines/luna/modules.nix | 10 +++---- machines/solis/modules.nix | 1 - machines/terra/modules.nix | 9 +++--- modules/apps/default.nix | 1 + modules/terminal/default.nix | 5 ---- modules/terminal/zsh.nix | 55 ------------------------------------ 6 files changed, 9 insertions(+), 72 deletions(-) delete mode 100644 modules/terminal/default.nix delete mode 100644 modules/terminal/zsh.nix diff --git a/machines/luna/modules.nix b/machines/luna/modules.nix index f49daa2..b9f1177 100644 --- a/machines/luna/modules.nix +++ b/machines/luna/modules.nix @@ -1,7 +1,6 @@ {...}: { imports = [ ../../modules - ../../modules/boot/loader/systemd.nix ]; config.horseman = { @@ -47,11 +46,10 @@ apps = { dev.enable = true; visual.enable = true; - terminal.enable = true; - }; - - terminal = { - zsh.enable = true; + terminal = { + enable = true; + zsh.enable = true; + }; }; }; } diff --git a/machines/solis/modules.nix b/machines/solis/modules.nix index a1540b9..8c93918 100644 --- a/machines/solis/modules.nix +++ b/machines/solis/modules.nix @@ -1,7 +1,6 @@ {...}: { imports = [ ../../modules - ../../modules/boot/loader/grub.nix ]; config.horseman = { diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index f9fb013..0c44ecd 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -57,11 +57,10 @@ apps = { dev.enable = true; visual.enable = true; - terminal.enable = true; - }; - - terminal = { - zsh.enable = true; + terminal = { + enable = true; + zsh.enable = true; + }; }; timers = { diff --git a/modules/apps/default.nix b/modules/apps/default.nix index c83ec2d..69fadf1 100644 --- a/modules/apps/default.nix +++ b/modules/apps/default.nix @@ -3,6 +3,7 @@ ./dev.nix ./terminal.nix + ./terminal/zsh.nix ./visual.nix ./visual/firefox.nix diff --git a/modules/terminal/default.nix b/modules/terminal/default.nix deleted file mode 100644 index da14057..0000000 --- a/modules/terminal/default.nix +++ /dev/null @@ -1,5 +0,0 @@ -{...}: { - imports = [ - ./zsh.nix - ]; -} diff --git a/modules/terminal/zsh.nix b/modules/terminal/zsh.nix deleted file mode 100644 index 95cf38c..0000000 --- a/modules/terminal/zsh.nix +++ /dev/null @@ -1,55 +0,0 @@ -{ - lib, - config, - pkgs, - ... -}: let - inherit (lib) mkEnableOption mkIf; - cfg = config.horseman.terminal.zsh; -in { - options = { - horseman.terminal.zsh = { - enable = mkEnableOption "The ZSH shell and plugins for it"; - }; - }; - - config = mkIf cfg.enable { - users.defaultUserShell = pkgs.zsh; - environment.shells = with pkgs; [zsh]; - - programs.zsh = { - enable = true; - enableCompletion = true; - - histSize = 10000; - - shellAliases = { - clone-dotfiles = "cp -r /home/horseman/nix-config/config/dotfiles/.\* /home/horseman/"; - rebuild = "function _rebuild(){clone-dotfiles && sudo nixos-rebuild switch --flake \"$@\" && nix fmt *}; _rebuild"; - update = "sudo nix flake update && git commit flake.lock -m 'Update flake.lock: $(date +%y-%m-%d)' && rebuild"; - compose = "sudo docker compose"; - wolpc = "wakeonlan D8:5E:D3:A8:B1:0A"; - capture-config = "nix run github:pjones/plasma-manager > ~/nix-config/modules/wm/plasma/default.nix"; - reboot-to-windows = "sudo efibootmgr -n 0000"; - mkdir = "mkdir -p"; - l = "ls -lAh --group-directories-first"; - zip = "zip -r"; - cat = "bat"; - py = "python3"; - }; - - ohMyZsh = { - enable = true; - plugins = [ - "zsh-interactive-cd" - "git-auto-fetch" - "wd" - ]; - theme = "theme"; - custom = "/home/horseman/nix-config/config/zsh"; - }; - - shellInit = "eval \"$(direnv hook zsh)\""; - }; - }; -} From c0db4f91c089cc39d026ceb407aedce12f8ba3b1 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 1 Sep 2025 19:18:20 +0200 Subject: [PATCH 2/5] reformat of files --- modules/apps/terminal/zsh.nix | 55 +++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 modules/apps/terminal/zsh.nix diff --git a/modules/apps/terminal/zsh.nix b/modules/apps/terminal/zsh.nix new file mode 100644 index 0000000..acabbe4 --- /dev/null +++ b/modules/apps/terminal/zsh.nix @@ -0,0 +1,55 @@ +{ + lib, + config, + pkgs, + ... +}: let + inherit (lib) mkEnableOption mkIf; + cfg = config.horseman.terminal.zsh; +in { + options = { + horseman.apps.terminal.zsh = { + enable = mkEnableOption "The ZSH shell and plugins for it"; + }; + }; + + config = mkIf cfg.enable { + users.defaultUserShell = pkgs.zsh; + environment.shells = with pkgs; [zsh]; + + programs.zsh = { + enable = true; + enableCompletion = true; + + histSize = 10000; + + shellAliases = { + clone-dotfiles = "cp -r /home/horseman/nix-config/config/dotfiles/.\* /home/horseman/"; + rebuild = "function _rebuild(){clone-dotfiles && sudo nixos-rebuild switch --flake \"$@\" && nix fmt *}; _rebuild"; + update = "sudo nix flake update && git commit flake.lock -m 'Update flake.lock: $(date +%y-%m-%d)' && rebuild"; + compose = "sudo docker compose"; + wolpc = "wakeonlan D8:5E:D3:A8:B1:0A"; + capture-config = "nix run github:pjones/plasma-manager > ~/nix-config/modules/wm/plasma/default.nix"; + reboot-to-windows = "sudo efibootmgr -n 0000"; + mkdir = "mkdir -p"; + l = "ls -lAh --group-directories-first"; + zip = "zip -r"; + cat = "bat"; + py = "python3"; + }; + + ohMyZsh = { + enable = true; + plugins = [ + "zsh-interactive-cd" + "git-auto-fetch" + "wd" + ]; + theme = "theme"; + custom = "/home/horseman/nix-config/config/zsh"; + }; + + shellInit = "eval \"$(direnv hook zsh)\""; + }; + }; +} From 2d60be7bf316956ac72b7798049528e24b3e28c0 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 1 Sep 2025 20:43:56 +0200 Subject: [PATCH 3/5] Add Steam --- machines/terra/modules.nix | 1 + modules/apps/default.nix | 2 ++ modules/apps/gaming.nix | 24 ++++++++++++++++++++++++ modules/apps/terminal/zsh.nix | 2 +- modules/default.nix | 1 - 5 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 modules/apps/gaming.nix diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index 0c44ecd..bce392e 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -57,6 +57,7 @@ apps = { dev.enable = true; visual.enable = true; + gaming.enable = true; terminal = { enable = true; zsh.enable = true; diff --git a/modules/apps/default.nix b/modules/apps/default.nix index 69fadf1..a5f32af 100644 --- a/modules/apps/default.nix +++ b/modules/apps/default.nix @@ -9,5 +9,7 @@ ./visual/firefox.nix ./server.nix + + ./gaming.nix ]; } diff --git a/modules/apps/gaming.nix b/modules/apps/gaming.nix new file mode 100644 index 0000000..a88704f --- /dev/null +++ b/modules/apps/gaming.nix @@ -0,0 +1,24 @@ +{ + lib, + config, + pkgs, + ... +}: let + inherit (lib) mkEnableOption mkIf; + cfg = config.horseman.apps.gaming; +in { + options = { + horseman.apps.gaming = { + enable = mkEnableOption "Games and things for games"; + }; + }; + + config = mkIf cfg.enable { + programs.steam = { + enable = true; + remotePlay.openFirewall = false; # Open ports in the firewall for Steam Remote Play + dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server + localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers + }; + }; +} diff --git a/modules/apps/terminal/zsh.nix b/modules/apps/terminal/zsh.nix index acabbe4..5c5642f 100644 --- a/modules/apps/terminal/zsh.nix +++ b/modules/apps/terminal/zsh.nix @@ -5,7 +5,7 @@ ... }: let inherit (lib) mkEnableOption mkIf; - cfg = config.horseman.terminal.zsh; + cfg = config.horseman.apps.terminal.zsh; in { options = { horseman.apps.terminal.zsh = { diff --git a/modules/default.nix b/modules/default.nix index ed09c87..650757a 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -3,7 +3,6 @@ ./apps ./hardware ./network - ./terminal ./wm ./users ./boot From 6771aabe46ecd7df0df9769482afef553b5e848a Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 1 Sep 2025 20:47:53 +0200 Subject: [PATCH 4/5] wofi improvements --- modules/wm/hyprland/keybindings.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index 42dd1e6..b019658 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -32,7 +32,7 @@ in { mods = ["SUPER"]; key = "SPACE"; dispatcher = "exec"; - params = "pkill wofi || wofi --show drun"; + params = "pkill wofi || wofi -i -S drun -M fuzzy"; } { From 38bee9c6ff583217f48243be1fb85b7f76c1f419 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Tue, 2 Sep 2025 22:52:39 +0200 Subject: [PATCH 5/5] switch wofi search mode --- modules/wm/hyprland/keybindings.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index b019658..26b50b4 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -32,7 +32,7 @@ in { mods = ["SUPER"]; key = "SPACE"; dispatcher = "exec"; - params = "pkill wofi || wofi -i -S drun -M fuzzy"; + params = "pkill wofi || wofi -i -S drun -M multi-contains"; } {