From 72dcc3de40843a660bc2b041559b0451d656b9ec Mon Sep 17 00:00:00 2001 From: Simon Cornet Date: Tue, 4 Jun 2024 11:54:06 +0200 Subject: [PATCH] [hyprland] feat: migrated config to home manager module --- nix/home/hyprland/default.nix | 13 +- nix/home/hyprland/hyprland-bindings.nix | 168 +++++++++++--------- nix/home/hyprland/hyprland-environment.nix | 45 +++--- nix/home/hyprland/hyprland-execution.nix | 88 +++++----- nix/home/hyprland/hyprland-general.nix | 41 +++-- nix/home/hyprland/hyprland-graphics.nix | 91 ++++++----- nix/home/hyprland/hyprland-input.nix | 39 +++-- nix/home/hyprland/hyprland-window_rules.nix | 135 ++++++++-------- nix/home/hyprland/hyprland.nix | 16 -- nix/systems/desktop.nix | 7 - 10 files changed, 332 insertions(+), 311 deletions(-) delete mode 100644 nix/home/hyprland/hyprland.nix diff --git a/nix/home/hyprland/default.nix b/nix/home/hyprland/default.nix index a1648e4..dc99c42 100644 --- a/nix/home/hyprland/default.nix +++ b/nix/home/hyprland/default.nix @@ -1,8 +1,15 @@ -{ ... }: -{ +{config, pkgs, ... }: +{ + # install hyprland + wayland.windowManager.hyprland = { + enable = true; + package = pkgs.unstable.hyprland; + xwayland.enable = true; + systemd.enable = true; + }; + imports = [ ./hypridle.nix - ./hyprland.nix ./hyprland-bindings.nix ./hyprland-environment.nix ./hyprland-execution.nix diff --git a/nix/home/hyprland/hyprland-bindings.nix b/nix/home/hyprland/hyprland-bindings.nix index e15e4e5..36e8fc2 100644 --- a/nix/home/hyprland/hyprland-bindings.nix +++ b/nix/home/hyprland/hyprland-bindings.nix @@ -1,98 +1,110 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/bindings.conf".text = '' + # hyprland binds config + wayland.windowManager.hyprland.settings = { - binds { - workspace_back_and_forth = true - } + binds = { + workspace_back_and_forth = true; + }; # bindings - $mainMod = SUPER + "$mainMod" = "SUPER"; # primary key bindings - bind = $mainMod, Return, exec, alacritty - bind = $mainMod, B, exec, blueman-manager - bind = $mainMod, C, exec, alacritty --class clipse --command clipse $PPID - bind = $mainMod, D, exec, ~/.dotfiles/apps/wofi/wofi.sh - bind = $mainMod, E, exec, nautilus --new-window - bind = $mainMod, J, togglesplit - bind = $mainMod, K, exec, alacritty --class scratchbox - bind = $mainMod, L, exec, hyprlock - bind = $mainMod, M, exit, - bind = $mainMod, N, exec, alacritty --class nmtui --command ~/.dotfiles/apps/hyprland/nmtui.sh - bind = $mainMod, P, exec, ~/.dotfiles/apps/hyprland/hypridle.sh toggle - bind = $mainMod, Q, killactive - bind = $mainMod, S, exec, ~/.dotfiles/apps/screenshot/screenshot.sh area - bind = ALT SHIFT, S, exec, ~/.dotfiles/apps/screenshot/screenshot.sh screen - bind = $mainMod, T, exec, alacritty --class nostt --command nostt - bind = $mainMod, V, togglefloating + bind = [ + + "$mainMod, Return, exec, alacritty" + "$mainMod, B, exec, blueman-manager" + "$mainMod, C, exec, alacritty --class clipse --command clipse $PPID" + "$mainMod, D, exec, ~/.dotfiles/apps/wofi/wofi.sh" + "$mainMod, E, exec, nautilus --new-window" + "$mainMod, J, togglesplit" + "$mainMod, K, exec, alacritty --class scratchbox" + "$mainMod, L, exec, hyprlock" + "$mainMod, M, exit," + "$mainMod, N, exec, alacritty --class nmtui --command ~/.dotfiles/apps/hyprland/nmtui.sh" + "$mainMod, P, exec, ~/.dotfiles/apps/hyprland/hypridle.sh toggle" + "$mainMod, Q, killactive" + "$mainMod, S, exec, ~/.dotfiles/apps/screenshot/screenshot.sh area" + "ALT SHIFT, S, exec, ~/.dotfiles/apps/screenshot/screenshot.sh screen" + "$mainMod, T, exec, alacritty --class nostt --command nostt" + "$mainMod, V, togglefloating" - # alternative key bindings - bind = ALT, F, fullscreen - bind = ALT, P, pseudo - bind = ALT, V, togglefloating + # alternative key bindings + "ALT, F, fullscreen" + "ALT, P, pseudo" + "ALT, V, togglefloating" - # manage lockscreen - bindl = ,switch:on:Lid Switch, exec, ~/.dotfiles/apps/swaylock/lock.sh + # focus bindings + "$mainMod, up, movefocus, u" + "$mainMod, down, movefocus, d" + "$mainMod, left, movefocus, l" + "$mainMod, right, movefocus, r" + + # switch workspace bindings + "$mainMod, 1, workspace, 1" + "$mainMod, 2, workspace, 2" + "$mainMod, 3, workspace, 3" + "$mainMod, 4, workspace, 4" + "$mainMod, 5, workspace, 5" + "$mainMod, 6, workspace, 6" + "$mainMod, 7, workspace, 7" + "$mainMod, 8, workspace, 8" + "$mainMod, 9, workspace, 9" + "$mainMod, 0, workspace, 10" - # focus bindings - bind = $mainMod, up, movefocus, u - bind = $mainMod, down, movefocus, d - bind = $mainMod, left, movefocus, l - bind = $mainMod, right, movefocus, r + # move window to workspaces bindings + "$mainMod SHIFT, 1, movetoworkspace, 1" + "$mainMod SHIFT, 2, movetoworkspace, 2" + "$mainMod SHIFT, 3, movetoworkspace, 3" + "$mainMod SHIFT, 4, movetoworkspace, 4" + "$mainMod SHIFT, 5, movetoworkspace, 5" + "$mainMod SHIFT, 6, movetoworkspace, 6" + "$mainMod SHIFT, 7, movetoworkspace, 7" + "$mainMod SHIFT, 8, movetoworkspace, 8" + "$mainMod SHIFT, 9, movetoworkspace, 9" + "$mainMod SHIFT, 0, movetoworkspace, 10" - # switch workspace bindings - bind = $mainMod, 1, workspace, 1 - bind = $mainMod, 2, workspace, 2 - bind = $mainMod, 3, workspace, 3 - bind = $mainMod, 4, workspace, 4 - bind = $mainMod, 5, workspace, 5 - bind = $mainMod, 6, workspace, 6 - bind = $mainMod, 7, workspace, 7 - bind = $mainMod, 8, workspace, 8 - bind = $mainMod, 9, workspace, 9 - bind = $mainMod, 0, workspace, 10 + # move workspaces using the mouse + "$mainMod, mouse_up, workspace, e+1" + "$mainMod, mouse_down, workspace, e-1" - # move window to workspaces bindings - bind = $mainMod SHIFT, 1, movetoworkspace, 1 - bind = $mainMod SHIFT, 2, movetoworkspace, 2 - bind = $mainMod SHIFT, 3, movetoworkspace, 3 - bind = $mainMod SHIFT, 4, movetoworkspace, 4 - bind = $mainMod SHIFT, 5, movetoworkspace, 5 - bind = $mainMod SHIFT, 6, movetoworkspace, 6 - bind = $mainMod SHIFT, 7, movetoworkspace, 7 - bind = $mainMod SHIFT, 8, movetoworkspace, 8 - bind = $mainMod SHIFT, 9, movetoworkspace, 9 - bind = $mainMod SHIFT, 0, movetoworkspace, 10 + # move window using keys + "ALT SHIFT, up, movewindow, u" + "ALT SHIFT, down, movewindow, d" + "ALT SHIFT, left, movewindow, l" + "ALT SHIFT, right, movewindow, r" - # move workspaces using the mouse - bind = $mainMod, mouse_up, workspace, e+1 - bind = $mainMod, mouse_down, workspace, e-1 + # resize window bindings + "$mainMod SHIFT, up, resizeactive, 0 -50" + "$mainMod SHIFT, down, resizeactive, 0 50" + "$mainMod SHIFT, left, resizeactive, -50 0" + "$mainMod SHIFT, right, resizeactive, 50 0" - # move window using keys - bind = ALT SHIFT, up, movewindow, u - bind = ALT SHIFT, down, movewindow, d - bind = ALT SHIFT, left, movewindow, l - bind = ALT SHIFT, right, movewindow, r + # multimedia key bindings + ",XF86AudioMute, exec, wpctl set-mute @DEFAULT_SINK@ toggle" + ",XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+" + ",XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-" + ",XF86MonBrightnessDown, exec, brightnessctl set 10%-" + ",XF86MonBrightnessUp, exec, brightnessctl set 10%+" + ]; - # move windows using the mouse - bindm = $mainMod, mouse:272, movewindow - bindm = $mainMod, mouse:273, resizewindow + # bindl section + bindl = [ - # resize window bindings - bind = $mainMod SHIFT, up, resizeactive, 0 -50 - bind = $mainMod SHIFT, down, resizeactive, 0 50 - bind = $mainMod SHIFT, left, resizeactive, -50 0 - bind = $mainMod SHIFT, right, resizeactive, 50 0 + # manage lockscreen + ",switch:on:Lid Switch, exec, ~/.dotfiles/apps/swaylock/lock.sh" - # multimedia key bindings - bind = ,XF86AudioMute, exec, wpctl set-mute @DEFAULT_SINK@ toggle - bind = ,XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+ - bind = ,XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%- - bind = ,XF86MonBrightnessDown, exec, brightnessctl set 10%- - bind = ,XF86MonBrightnessUp, exec, brightnessctl set 10%+ + ]; - ''; + # bindm section + bindm = [ + + # move windows using the mouse + "$mainMod, mouse:272, movewindow" + "$mainMod, mouse:273, resizewindow" + + ]; + }; } diff --git a/nix/home/hyprland/hyprland-environment.nix b/nix/home/hyprland/hyprland-environment.nix index 53c7990..be92460 100644 --- a/nix/home/hyprland/hyprland-environment.nix +++ b/nix/home/hyprland/hyprland-environment.nix @@ -1,27 +1,30 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/environment.conf".text = '' - - # firefox - env = MOZ_ENABLE_WAYLAND,1 - - # electron - env = ELECTRON_OZONE_PLATFORM_HINT,auto + # hyprland environment variables + wayland.windowManager.hyprland.settings = { - # desktop frameworks - env = CLUTTER_BACKEND,wayland - env = GDK_BACKEND,wayland,x11 - env = QT_AUTO_SCREEN_SCALE_FACTOR,1 - env = QT_QPA_PLATFORM,wayland;xcb - env = QT_QPA_PLATFORMTHEME,qt5ct - env = QT_QPA_PLATFORMTHEME,qt6ct - env = QT_SCALE_FACTOR,1 - env = QT_WAYLAND_DISABLE_WINDOWDECORATION,1 - env = XDG_CURRENT_DESKTOP,Hyprland - env = XDG_SESSION_DESKTOP,Hyprland - env = XDG_SESSION_TYPE,wayland + env = [ - ''; + # firefox + "MOZ_ENABLE_WAYLAND,1" + + # electron + "ELECTRON_OZONE_PLATFORM_HINT,auto" + + # desktop frameworks + "CLUTTER_BACKEND,wayland" + "GDK_BACKEND,wayland,x11" + "QT_AUTO_SCREEN_SCALE_FACTOR,1" + "QT_QPA_PLATFORM,wayland;xcb" + "QT_QPA_PLATFORMTHEME,qt5ct" + "QT_QPA_PLATFORMTHEME,qt6ct" + "QT_SCALE_FACTOR,1" + "QT_WAYLAND_DISABLE_WINDOWDECORATION,1" + "XDG_CURRENT_DESKTOP,Hyprland" + "XDG_SESSION_DESKTOP,Hyprland" + "XDG_SESSION_TYPE,wayland" + + ]; + }; } diff --git a/nix/home/hyprland/hyprland-execution.nix b/nix/home/hyprland/hyprland-execution.nix index a1c2d33..0c1a968 100644 --- a/nix/home/hyprland/hyprland-execution.nix +++ b/nix/home/hyprland/hyprland-execution.nix @@ -1,55 +1,65 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/executions.conf".text = '' + # hyprland environment variables + wayland.windowManager.hyprland.settings = { - # start waybar - exec = ~/.dotfiles/apps/waybar/startup.sh + # execute always + exec = [ - # set monitor workspaces - exec = ~/.dotfiles/apps/hyprland/monitor.sh + # start waybar + "~/.dotfiles/apps/waybar/startup.sh" - # start tailscale - exec-once = tailscale up + # set monitor workspaces + "~/.dotfiles/apps/hyprland/monitor.sh" - # clear and start clipse - exec-once = clipse -clear - exec-once = clipse -listen + # start blueman + "blueman-tray" - # start blueman - exec = blueman-tray + # set wallpaper + "~/.dotfiles/apps/wallpaper/startup.sh" - # start hypridle - exec-once = hypridle + # center apps + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"blueman-manager\" --title \"Bluetooth Devices\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"clipse\" --title \"Alacritty\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"com.gabm.satty\" --title \"satty\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"dev.deedles.Trayscale\" --title \"Trayscale\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"nmtui\" --title \"Alacritty\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"nostt\" --title \"Alacritty\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"pavucontrol\" --title \"Volume Control\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"Rofi\" --title \"rofi -  Apps\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"scratchbox\" --title \"Alacritty\"" + "~/.dotfiles/apps/hyprland/centre_app.sh --class \"solaar\" --title \"solaar\"" - # theming - exec = ~/.dotfiles/apps/wallpaper/startup.sh + ]; - # set volume - exec-once = pw-volume change 80% + # execute once + exec-once = [ - # solaar - exec-once = ~/.dotfiles/apps/hyprland/startup/solaar.sh + # start tailscale + "tailscale up" - # nextcloud desktop - exec-once = ~/.dotfiles/apps/hyprland/startup/nextcloud_desktop.sh + # clear and start clipse + "clipse -clear" + "clipse -listen" - # center apps - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "blueman-manager" --title "Bluetooth Devices" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "clipse" --title "Alacritty" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "com.gabm.satty" --title "satty" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "dev.deedles.Trayscale" --title "Trayscale" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "nmtui" --title "Alacritty" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "nostt" --title "Alacritty" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "pavucontrol" --title "Volume Control" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "Rofi" --title "rofi -  Apps" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "scratchbox" --title "Alacritty" - exec = ~/.dotfiles/apps/hyprland/centre_app.sh --class "solaar" --title "solaar" + # start hypridle + "hypridle" - # start default apps - exec-once = [workspace 1 silent] bitwarden - exec-once = [workspace 2 silent] firefox - exec-once = [workspace 3 silent] alacritty - ''; + # set volume + "pw-volume change 80%" + + # solaar + "~/.dotfiles/apps/hyprland/startup/solaar.sh" + + # nextcloud desktop + "~/.dotfiles/apps/hyprland/startup/nextcloud_desktop.sh" + + # start default apps + "[workspace 1 silent] bitwarden" + "[workspace 2 silent] firefox" + "[workspace 3 silent] alacritty" + + ]; + }; } diff --git a/nix/home/hyprland/hyprland-general.nix b/nix/home/hyprland/hyprland-general.nix index ff78ac9..4ff5ad2 100644 --- a/nix/home/hyprland/hyprland-general.nix +++ b/nix/home/hyprland/hyprland-general.nix @@ -1,34 +1,33 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/general.conf".text = '' + # hyprland general config + wayland.windowManager.hyprland.settings = { # dwindle secion - dwindle { - pseudotile = yes - preserve_split = yes - special_scale_factor = 0.8 - } + dwindle = { + pseudotile = true; + preserve_split = true; + special_scale_factor = "0.8"; + }; # general section - general { - border_size = 3 + general = { + border_size = "3"; - col.active_border = rgba(528bffaa) rgba(043a8baa) 45deg - col.inactive_border = rgba(595959aa) + "col.active_border" = "rgba(528bffaa) rgba(043a8baa) 45deg"; + "col.inactive_border" = "rgba(595959aa)"; - gaps_in = 5 - gaps_out = 20 + gaps_in = "5"; + gaps_out = "20"; - layout = dwindle - } + layout = "dwindle"; + }; # misc section - misc { - disable_hyprland_logo = true - disable_splash_rendering = true - } - - ''; + misc = { + disable_hyprland_logo = true; + disable_splash_rendering = true; + }; + }; } diff --git a/nix/home/hyprland/hyprland-graphics.nix b/nix/home/hyprland/hyprland-graphics.nix index 15f07c6..8abea63 100644 --- a/nix/home/hyprland/hyprland-graphics.nix +++ b/nix/home/hyprland/hyprland-graphics.nix @@ -1,63 +1,70 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/graphics.conf".text = '' + # hyprland general config + wayland.windowManager.hyprland.settings = { + + monitor = [ - # main monitors - monitor = eDP-1, 1920x1200@60, 760x1440, 1 # laptop (native: 2560x1600@60, preffered 1920x1200) - monitor = HDMI-A-1, 1920x1080@60, 0x0, 1 # force 1080p on hdmi output - monitor = , preferred, 0x0, 1 # default resolution on any other screen + # main monitors + "eDP-1, 1920x1200@60, 760x1440, 1" + "HDMI-A-1, 1920x1080@60, 0x0, 1" + ", preferred, 0x0, 1" + + ]; # unscale xwayland - xwayland { - force_zero_scaling = true - } + xwayland = { + force_zero_scaling = true; + }; # animation section - animations { - enabled = yes + animations = { + enabled = true; - bezier = fade, 0.05, 1, 0.1, 1 - bezier = smoothOut, 0.36, 0, 0.66, 1 - bezier = smoothIn, 0.25, 1, 0.5, 1 - bezier = liner, 1, 1, 1, 1 + bezier = [ + "fade, 0.05, 1, 0.1, 1" + "smoothOut, 0.36, 0, 0.66, 1" + "smoothIn, 0.25, 1, 0.5, 1" + "liner, 1, 1, 1, 1" + ]; - animation = windows, 1, 3, smoothIn, - animation = windowsOut, 1, 3, smoothOut, - animation = windowsMove, 1, 3, default - animation = border, 1, 10, default - animation = borderangle, 1, 45, liner, loop - animation = fade, 1, 5, smoothIn - animation = fadeDim, 1, 5, smoothIn - animation = workspaces, 1, 8, fade - } + animation = [ + "windows, 1, 3, smoothIn" + "windowsOut, 1, 3, smoothOut" + "windowsMove, 1, 3, default" + "border, 1, 10, default" + "borderangle, 1, 45, liner, loop" + "fade, 1, 5, smoothIn" + "fadeDim, 1, 5, smoothIn" + "workspaces, 1, 8, fade" + ]; + }; # decoration section - decoration { + decoration = { # blur - blur { - enabled = true - size = 2 - passes = 2 - } + blur = { + enabled = true; + size = "2"; + passes = "2"; + }; # windows - rounding = 16 + rounding = "16"; # shadows - drop_shadow = true - shadow_offset = 2 2 - shadow_range = 8 - shadow_render_power = 2 - shadow_ignore_window = true - col.shadow = 0x66000000 + drop_shadow = true; + shadow_offset = "2 2"; + shadow_range = "8"; + shadow_render_power = "2"; + shadow_ignore_window = true; + "col.shadow" = "0x66000000"; # opacity - active_opacity = 1.0 - inactive_opacity = 1.0 - } - - ''; + active_opacity = "1.0"; + inactive_opacity = "1.0"; + }; + }; } diff --git a/nix/home/hyprland/hyprland-input.nix b/nix/home/hyprland/hyprland-input.nix index 0e2c9aa..000c854 100644 --- a/nix/home/hyprland/hyprland-input.nix +++ b/nix/home/hyprland/hyprland-input.nix @@ -1,29 +1,28 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/input.conf".text = '' + # hyprland general config + wayland.windowManager.hyprland.settings = { # gesture secion - gestures { - workspace_swipe = true - workspace_swipe_min_speed_to_force = 80 - workspace_swipe_cancel_ratio = 0.2 - } + gestures = { + workspace_swipe = true; + workspace_swipe_min_speed_to_force = "80"; + workspace_swipe_cancel_ratio = "0.2"; + }; # input section - input { - kb_layout = us - follow_mouse = 1 - sensitivity = 0 + input = { + kb_layout = "us"; + follow_mouse = "1"; + sensitivity = "0"; - touchpad { - disable_while_typing = true - drag_lock = true - natural_scroll = true - tap-and-drag = true - } - } - - ''; + touchpad = { + disable_while_typing = true; + drag_lock = true; + natural_scroll = true; + tap-and-drag = true; + }; + }; + }; } diff --git a/nix/home/hyprland/hyprland-window_rules.nix b/nix/home/hyprland/hyprland-window_rules.nix index 41dac94..65e0635 100644 --- a/nix/home/hyprland/hyprland-window_rules.nix +++ b/nix/home/hyprland/hyprland-window_rules.nix @@ -1,83 +1,90 @@ { config, ... }: { - # include hyprland configs - home.file.".config/hypr/window_rules.conf".text = '' + # hyprland general config + wayland.windowManager.hyprland.settings = { - # window rules - windowrule = float, confirm|confirmreset - windowrule = float, dialog|download - windowrule = float, error|eog - windowrule = float, file-roller|file_progress - windowrule = float, Lxappearance|notification - windowrule = float, splash - windowrule = float, title:branchdialog - windowrule = float, title:Nextcloud + windowrule = [ - # alacritty - windowrulev2 = float, class:(scratchbox) - windowrulev2 = size 1200 800, class:(scratchbox) - windowrulev2 = move center, class:(scratchbox) + # window rules + "float, confirm|confirmreset" + "float, dialog|download" + "float, error|eog" + "float, file-roller|file_progress" + "float, Lxappearance|notification" + "float, splash" + "float, title:branchdialog" + "float, title:Nextcloud" - # blueman - windowrulev2 = float, class:(blueman-manager), title:(Bluetooth Devices) - windowrulev2 = size 1000 800, class:(blueman-manager), title:(Bluetooth Devices) - windowrulev2 = move center, class:(blueman-manager), title:(Bluetooth Devices) + ]; - # clipse - windowrulev2 = float, class:(clipse) - windowrulev2 = size 1000 800, class:(clipse) - windowrulev2 = move center, class:(clipse) + windowrulev2 = [ - # save as - windowrulev2 = float, title:(Save As) - windowrulev2 = size 1000 800, title:(Save As) - windowrulev2 = move center, title:(Save As) + # alacritty + "float, class:(scratchbox)" + "size 1200 800, class:(scratchbox)" + "move center, class:(scratchbox)" - # open file - windowrulev2 = float, title:(Open File) - windowrulev2 = size 1000 800, title:(Open File) - windowrulev2 = move center, title:(Open File) + # blueman + "float, class:(blueman-manager), title:(Bluetooth Devices)" + "size 1000 800, class:(blueman-manager), title:(Bluetooth Devices)" + "move center, class:(blueman-manager), title:(Bluetooth Devices)" - # add folder to workspace - windowrulev2 = float, title:(Add Folder to Workspace) - windowrulev2 = size 1000 800, title:(Add Folder to Workspace) - windowrulev2 = move center, title:(Add Folder to Workspace) + # clipse + "float, class:(clipse)" + "size 1000 800, class:(clipse)" + "move center, class:(clipse)" - # network manager tui - windowrulev2 = float, class:(nmtui), title:(Alacritty) - windowrulev2 = size 1180 792, class:(nmtui), title:(Alacritty) - windowrulev2 = move center, class:(nmtui), title:(Alacritty) + # save as + "float, title:(Save As)" + "size 1000 800, title:(Save As)" + "move center, title:(Save As)" - # nos teletekst - windowrulev2 = float, class:(nostt), title:(Alacritty) - windowrulev2 = size 455 660, class:(nostt), title:(Alacritty) - windowrulev2 = move center, class:(nostt), title:(Alacritty) + # open file + "float, title:(Open File)" + "size 1000 800, title:(Open File)" + "move center, title:(Open File)" - # satty - windowrulev2 = float, class:(com.gabm.satty), title:(satty) - windowrulev2 = size 1400 900, class:(com.gabm.satty), title:(satty) - windowrulev2 = move center, class:(com.gabm.satty), title:(satty) + # add folder to workspace + "float, title:(Add Folder to Workspace)" + "size 1000 800, title:(Add Folder to Workspace)" + "move center, title:(Add Folder to Workspace)" - # solaar - windowrulev2 = float, class:(solaar), title:(solaar) - windowrulev2 = size 1000 800, class:(solaar), title:(solaar) - windowrulev2 = move center, class:(solaar), title:(solaar) + # network manager tui + "float, class:(nmtui), title:(Alacritty)" + "size 1180 792, class:(nmtui), title:(Alacritty)" + "move center, class:(nmtui), title:(Alacritty)" - # trayscale - windowrulev2 = float, class:(dev.deedles.Trayscale), title:(Trayscale) - windowrulev2 = size 1000 800, class:(dev.deedles.Trayscale), title:(Trayscale) - windowrulev2 = move center, class:(dev.deedles.Trayscale), title:(Trayscale) + # nos teletekst + "float, class:(nostt), title:(Alacritty)" + "size 455 660, class:(nostt), title:(Alacritty)" + "move center, class:(nostt), title:(Alacritty)" - # volume control - windowrulev2 = float, title:(Volume Control) - windowrulev2 = size 1000 800, title:(Volume Control) - windowrulev2 = move center, title:(Volume Control) + # satty + "float, class:(com.gabm.satty), title:(satty)" + "size 1400 900, class:(com.gabm.satty), title:(satty)" + "move center, class:(com.gabm.satty), title:(satty)" - # wofi - windowrulev2 = forceinput, class:(wofi) - windowrulev2 = windowdance, class:(wofi) - windowrulev2 = stayfocused, class:(wofi) + # solaar + "float, class:(solaar), title:(solaar)" + "size 1000 800, class:(solaar), title:(solaar)" + "move center, class:(solaar), title:(solaar)" - ''; + # trayscale + "float, class:(dev.deedles.Trayscale), title:(Trayscale)" + "size 1000 800, class:(dev.deedles.Trayscale), title:(Trayscale)" + "move center, class:(dev.deedles.Trayscale), title:(Trayscale)" + + # volume control + "float, title:(Volume Control)" + "size 1000 800, title:(Volume Control)" + "move center, title:(Volume Control)" + + # wofi + "forceinput, class:(wofi)" + "windowdance, class:(wofi)" + "stayfocused, class:(wofi)" + + ]; + }; } diff --git a/nix/home/hyprland/hyprland.nix b/nix/home/hyprland/hyprland.nix deleted file mode 100644 index 9aed6bc..0000000 --- a/nix/home/hyprland/hyprland.nix +++ /dev/null @@ -1,16 +0,0 @@ -{ config, pkgs, ... }: -{ - - # include hyprland configs - home.file.".config/hypr/hyprland.conf".text = '' - - source = ~/.config/hypr/environment.conf - source = ~/.config/hypr/executions.conf - source = ~/.config/hypr/general.conf - source = ~/.config/hypr/graphics.conf - source = ~/.config/hypr/input.conf - source = ~/.config/hypr/window_rules.conf - source = ~/.config/hypr/bindings.conf - - ''; -} diff --git a/nix/systems/desktop.nix b/nix/systems/desktop.nix index 62a7940..952cf12 100644 --- a/nix/systems/desktop.nix +++ b/nix/systems/desktop.nix @@ -17,13 +17,6 @@ services.xserver.displayManager.gdm.enable = true; services.xserver.desktopManager.gnome.enable = true; - # hyprland - programs.hyprland = { - enable = true; - package = pkgs.unstable.hyprland; - xwayland.enable = true; - }; - # environment variables for hyprland environment.sessionVariables = {