From c4c07a043a9554ebd6e38533f9fed3a52e1195b6 Mon Sep 17 00:00:00 2001 From: Nick Date: Fri, 9 May 2025 23:12:45 -0500 Subject: [PATCH] feat: tweaking niri --- flake.nix | 1 + modules/home/default.nix | 9 +- modules/home/gui/desktop/niri/default.nix | 11 +- .../wayland/waybar/config/settings.nix | 46 +++--- .../desktop/wayland/waybar/config/style.nix | 135 +++++++++--------- modules/nixos/default.nix | 6 +- .../nixos/desktop/wayland/greetd/default.nix | 2 +- 7 files changed, 107 insertions(+), 103 deletions(-) diff --git a/flake.nix b/flake.nix index 869d5f5..95cab43 100755 --- a/flake.nix +++ b/flake.nix @@ -112,6 +112,7 @@ config.nixosModules.crust inputs.home-manager.nixosModules.home-manager inputs.lix-module.nixosModules.default + inputs.niri.nixosModules.niri inputs.nur.modules.nixos.default inputs.sops-nix.nixosModules.sops ]; diff --git a/modules/home/default.nix b/modules/home/default.nix index fb28f7a..5552742 100755 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -188,7 +188,8 @@ in usbImager virtManager # hypr - # wayland + niri + wayland theming # polychromatic dolphin @@ -215,7 +216,8 @@ in bitwarden emote # hypr - # wayland + wayland + niri theming ; }; @@ -237,6 +239,9 @@ in videoPlaying discord signal + niri + wayland + theming tools ; }; diff --git a/modules/home/gui/desktop/niri/default.nix b/modules/home/gui/desktop/niri/default.nix index dbcf3fa..935a17c 100755 --- a/modules/home/gui/desktop/niri/default.nix +++ b/modules/home/gui/desktop/niri/default.nix @@ -169,6 +169,7 @@ in outputs = { "DP-1" = { background-color = makeColour el.base02; + scale = 1.0; mode = { width = 2560; height = 1080; @@ -218,7 +219,6 @@ in let windowMatch = c: { app-id = c; - opacity = 1.0; }; appIDs = [ "floop" @@ -231,13 +231,13 @@ in ]; in builtins.map windowMatch appIDs; + opacity = 1.0; } { matches = let windowMatch = c: { app-id = c; - open-on-workspace = workspace0; }; appIDs = [ "signal" @@ -245,13 +245,13 @@ in ]; in builtins.map windowMatch appIDs; + open-on-workspace = workspace0; } { matches = let windowMatch = c: { app-id = c; - open-on-workspace = workspace1; }; appIDs = [ "code" @@ -259,13 +259,13 @@ in ]; in builtins.map windowMatch appIDs; + open-on-workspace = workspace1; } { matches = let windowMatch = c: { app-id = c; - open-on-workspace = workspace2; }; appIDs = [ "steam" @@ -273,13 +273,13 @@ in ]; in builtins.map windowMatch appIDs; + open-on-workspace = workspace2; } { matches = let windowMatch = c: { app-id = c; - open-on-workspace = workspace3; }; appIDs = [ "feishin" @@ -287,6 +287,7 @@ in ]; in builtins.map windowMatch appIDs; + open-on-workspace = workspace3; } { clip-to-geometry = true; diff --git a/modules/home/gui/desktop/wayland/waybar/config/settings.nix b/modules/home/gui/desktop/wayland/waybar/config/settings.nix index e24ce88..5c03305 100755 --- a/modules/home/gui/desktop/wayland/waybar/config/settings.nix +++ b/modules/home/gui/desktop/wayland/waybar/config/settings.nix @@ -12,12 +12,13 @@ in margin-left = 5; margin-right = 5; modules-left = [ - "custom/launcher" - "hyprland/workspaces" + "custom/weather" + # "niri/workspaces" ]; modules-center = [ - "custom/weather" + # "custom/launcher" + "clock" ]; modules-right = [ @@ -29,7 +30,7 @@ in "pulseaudio" # "network" "battery" - "clock" + # "clock" ]; clock = { @@ -44,29 +45,20 @@ in format-alt = " {:%d/%m}"; }; - "hyprland/workspaces" = { - active-only = false; - disable-scroll = true; - format = "{icon}"; - on-click = "activate"; - format-icons = { - "1" = "◉"; - "2" = "◉"; - "3" = "◉"; - "4" = "◉"; - "5" = "◉"; - urgent = ""; - default = "◉"; - sort-by-number = true; - }; - persistent-workspaces = { - "1" = [ ]; - "2" = [ ]; - "3" = [ ]; - "4" = [ ]; - "5" = [ ]; - }; - }; + # "niri/workspaces" = { + # active-only = false; + # disable-scroll = true; + # format = "{icon}"; + # on-click = "activate"; + # format-icons = { + # # focused = "◉"; + # # active = "◉"; + # # empty = "◯"; + # # urgent = ""; + # # default = "◯"; + # # sort-by-number = true; + # }; + # }; memory = { format = "󰟜 {}%"; diff --git a/modules/home/gui/desktop/wayland/waybar/config/style.nix b/modules/home/gui/desktop/wayland/waybar/config/style.nix index 5ce2783..c46b407 100755 --- a/modules/home/gui/desktop/wayland/waybar/config/style.nix +++ b/modules/home/gui/desktop/wayland/waybar/config/style.nix @@ -40,82 +40,87 @@ let in '' - * { - min-height: 0px; - font-family: ${custom.font}; - font-weight: ${custom.font_weight}; - } - - window#waybar { - background: #${custom.background_2}; - color: #${custom.background_3}; - border: 2px solid; - border-radius: 30px; - border-color: #${custom.text_color}; - min-height: 100px; - opacity: ${custom.opacityBg}; + * { + min-height: 30px; + border-radius: 0; + font-family: ${custom.font}; + font-weight: ${custom.font_weight}; } - #workspaces { - font-size: 18px; - padding-left: 15px; - margin-bottom: 2px; - } - #workspaces button { - color: #${custom.button_color}; - padding: 5px; - opacity: ${custom.opacityBt}; - } - #workspaces button.empty { - color: #${custom.background_3}; - } - #workspaces button.active { - color: #${custom.text_color}; - } + window#waybar { + background: #${custom.background_2}; + color: #${custom.text_color}; + border: 2px solid; + border-radius: 30px; + border-color: #${custom.text_color}; + opacity: ${custom.opacityBg}; + } - #tray, #pulseaudio, #privacy, #cpu, #memory, #disk, #clock { - font-size: ${custom.font_size}; - color: #${custom.text_color}; - padding-right: 10px; - } + #workspaces { + font-size: 18px; + padding-left: 15px; + margin-bottom: 2px; + } + #workspaces button { + color: #${custom.button_color}; + padding: 5px 0px 5px 0px; + } + #workspaces button.active { + color: #${custom.text_color}; + } + #workspaces button.empty { + color: #${custom.button_color}; + } + #workspaces button.focused { + color: #${custom.text_color}; + } - #privacy { - } + #tray, #pulseaudio, #privacy, #cpu, #memory, #disk, #clock { + font-size: ${custom.font_size}; + color: #${custom.text_color}; + padding-right: 10px; + } - #cpu { - } + #privacy { + } - #memory { - } + #cpu { + } - #disk { - } + #memory { + } - #tray { - } + #disk { + } - #pulseaudio { - } + #tray { + } - #clock { - } + #pulseaudio { + } - #battery { - font-size: ${custom.font_size}; - color: #${custom.text_color}; - padding-right: 10px; - } + #clock { + font-size: 14px; + } - #custom-launcher { - font-size: 20px; - color: #${custom.text_color}; - font-weight: ${custom.font_weight}; - padding-left: 10px; - } + #battery { + font-size: ${custom.font_size}; + color: #${custom.text_color}; + padding-right: 10px; + } - #custom-weather { - font-size: 14px; - color: #${custom.text_color}; - font-weight: ${custom.font_weight}; - } + #custom-launcher { + font-size: 20px; + color: #${custom.text_color}; + font-weight: ${custom.font_weight}; + padding-left: 10px; + padding-right: 10px; + } + + #custom-weather { + font-size: 14px; + color: #${custom.text_color}; + font-weight: ${custom.font_weight}; + padding-left: 10px; + } '' diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix index 7a25e34..88dfcb7 100755 --- a/modules/nixos/default.nix +++ b/modules/nixos/default.nix @@ -37,9 +37,9 @@ in deimos = { imports = builtins.attrValues { inherit (modules) - # hypr - # wayland - plasma + niri + wayland + # plasma sddm flatpak xserver diff --git a/modules/nixos/desktop/wayland/greetd/default.nix b/modules/nixos/desktop/wayland/greetd/default.nix index 8bc098f..a5cb1b3 100755 --- a/modules/nixos/desktop/wayland/greetd/default.nix +++ b/modules/nixos/desktop/wayland/greetd/default.nix @@ -21,7 +21,7 @@ in { services = { greetd = { - enable = true; + enable = false; vt = 7; settings = { default_session = {