From 865e47f0ce0ef7673b7925f9020bcb2fcde0e456 Mon Sep 17 00:00:00 2001 From: Evie Litherland-Smith Date: Tue, 18 Jul 2023 16:24:27 +0100 Subject: [PATCH] Rename workspaces, update clock widget format --- Makefile | 2 + home/hyprland/hyprland.conf | 78 ++++++++++--------- home/hyprland/waybar/default.nix | 2 +- home/hyprland/waybar/modules/clock.nix | 4 +- .../waybar/modules/wlr_workspaces.nix | 31 +++++--- home/shell/starship.toml | 2 +- hosts/Ronin/home.nix | 11 ++- 7 files changed, 73 insertions(+), 57 deletions(-) diff --git a/Makefile b/Makefile index e625339d..6700ce26 100644 --- a/Makefile +++ b/Makefile @@ -27,3 +27,5 @@ waybar: home: nix run nixpkgs#home-manager -- switch --flake . + make hyprland + make waybar diff --git a/home/hyprland/hyprland.conf b/home/hyprland/hyprland.conf index 4f406853..ef69bd51 100644 --- a/home/hyprland/hyprland.conf +++ b/home/hyprland/hyprland.conf @@ -18,6 +18,7 @@ env = XCURSOR_SIZE,24 env = QT_AUTO_SCREEN_SCALE_FACTOR=1 env = QT_QPA_PLATFORM=wayland;xcb env = QT_WAYLAND_DISABLE_WINDOWDECORATION=1 +env = MOZ_ENABLE_WAYLAND=1 input { kb_layout = gb @@ -106,33 +107,33 @@ bind = SUPER SHIFT, L, movewindow, r bind = SUPER SHIFT, K, movewindow, u bind = SUPER SHIFT, J, movewindow, d -bind = SUPER, A, moveworkspacetomonitor, 1 current -bind = SUPER, A, workspace, 1 -bind = SUPER SHIFT, A, movetoworkspace, 1 -bind = SUPER, D, moveworkspacetomonitor, 2 current -bind = SUPER, D, workspace, 2 -bind = SUPER SHIFT, D, movetoworkspace, 2 -bind = SUPER, W, moveworkspacetomonitor, 3 current -bind = SUPER, W, workspace, 3 -bind = SUPER SHIFT, W, movetoworkspace, 3 -bind = SUPER, F, moveworkspacetomonitor, 4 current -bind = SUPER, F, workspace, 4 -bind = SUPER SHIFT, F, movetoworkspace, 4 -bind = SUPER, C, moveworkspacetomonitor, 5 current -bind = SUPER, C, workspace, 5 -bind = SUPER SHIFT, C, movetoworkspace, 5 -bind = SUPER, R, moveworkspacetomonitor, 6 current -bind = SUPER, R, workspace, 6 -bind = SUPER SHIFT, R, movetoworkspace, 6 -bind = SUPER, S, moveworkspacetomonitor, 7 current -bind = SUPER, S, workspace, 7 -bind = SUPER SHIFT, S, movetoworkspace, 7 -bind = SUPER, 8, moveworkspacetomonitor, 8 current -bind = SUPER, 8, workspace, 8 -bind = SUPER SHIFT, 8, movetoworkspace, 8 -bind = SUPER, 9, moveworkspacetomonitor, 9 current -bind = SUPER, 9, workspace, 9 -bind = SUPER SHIFT, 9, movetoworkspace, 9 +bind = SUPER, A, moveworkspacetomonitor, name:home current +bind = SUPER, A, workspace, name:home +bind = SUPER SHIFT, A, movetoworkspace, name:home +bind = SUPER, D, moveworkspacetomonitor, name:dev current +bind = SUPER, D, workspace, name:dev +bind = SUPER SHIFT, D, movetoworkspace, name:dev +bind = SUPER, W, moveworkspacetomonitor, name:browser current +bind = SUPER, W, workspace, name:browser +bind = SUPER SHIFT, W, movetoworkspace, name:browser +bind = SUPER, F, moveworkspacetomonitor, name:files current +bind = SUPER, F, workspace, name:files +bind = SUPER SHIFT, F, movetoworkspace, name:files +bind = SUPER, C, moveworkspacetomonitor, name:chat current +bind = SUPER, C, workspace, name:chat +bind = SUPER SHIFT, C, movetoworkspace, name:chat +bind = SUPER, Z, moveworkspacetomonitor, name:mail current +bind = SUPER, Z, workspace, name:mail +bind = SUPER SHIFT, Z, movetoworkspace, name:mail +bind = SUPER, R, moveworkspacetomonitor, name:remote current +bind = SUPER, R, workspace, name:remote +bind = SUPER SHIFT, R, movetoworkspace, name:remote +bind = SUPER, S, moveworkspacetomonitor, name:steam current +bind = SUPER, S, workspace, name:steam +bind = SUPER SHIFT, S, movetoworkspace, name:steam +bind = SUPER, X, moveworkspacetomonitor, name:misc current +bind = SUPER, X, workspace, name:misc +bind = SUPER SHIFT, X, movetoworkspace, name:misc bind = SUPER, period, workspace, m+1 bind = SUPER SHIFT, period, movetoworkspace, r+1 @@ -155,17 +156,18 @@ bindm = SUPER, mouse:272, movewindow bindm = SUPER, mouse:273, resizewindow # See https://wiki.hyprland.org/Configuring/Window-Rules/ for more -windowrule = workspace 2,(neovide) -windowrule = workspace 3,(firefox) -windowrule = workspace 4,^(libreoffice).* -windowrule = workspace 4,(Zotero) -windowrule = workspace 5,(Signal) -windowrule = workspace 5,(fractal) -windowrule = workspace 5,(discord) -windowrule = workspace 5,(teams-for-linux) -windowrule = workspace 6,(Nxplayer.bin) -windowrule = workspace 7,^(steam).* -windowrule = workspace 7,(.gamescope-wrapped) +windowrule = workspace name:dev,(neovide) +windowrule = workspace name:browser,(firefox) +windowrule = workspace name:files,^(libreoffice).* +windowrule = workspace name:files,(Zotero) +windowrule = workspace name:chat,(Signal) +windowrule = workspace name:chat,(fractal) +windowrule = workspace name:chat,(discord) +windowrule = workspace name:chat,(teams-for-linux) +windowrule = workspace name:mail,(thunderbird) +windowrule = workspace name:remote,(Nxplayer.bin) +windowrule = workspace name:steam,^(steam).* +windowrule = workspace name:steam,(.gamescope-wrapped) windowrule = float,(foot) windowrule = center,(foot) diff --git a/home/hyprland/waybar/default.nix b/home/hyprland/waybar/default.nix index bb3cc6c6..49c1fca0 100644 --- a/home/hyprland/waybar/default.nix +++ b/home/hyprland/waybar/default.nix @@ -25,7 +25,7 @@ cpu = import ./modules/cpu.nix; memory = import ./modules/memory.nix; temperature = import ./modules/temperature.nix; - clock = import ./modules/clock.compact.nix; + clock = import ./modules/clock.nix; pulseaudio = import ./modules/pulseaudio.nix; bluetooth = import ./modules/bluetooth.compact.nix; network = import ./modules/network.compact.nix; diff --git a/home/hyprland/waybar/modules/clock.nix b/home/hyprland/waybar/modules/clock.nix index 3532080e..6348703b 100644 --- a/home/hyprland/waybar/modules/clock.nix +++ b/home/hyprland/waybar/modules/clock.nix @@ -1,6 +1,6 @@ { - format = "{:%R 󰅐 }"; - # format-alt = "{:%A %Y-%m-%d 󰃭 }"; + format = "{:%a %d %b %R}"; + format-alt = "{:%A %F %T}"; tooltip-format = "{calendar}"; calendar = { mode = "month"; diff --git a/home/hyprland/waybar/modules/wlr_workspaces.nix b/home/hyprland/waybar/modules/wlr_workspaces.nix index dae94d1c..ec28fc92 100644 --- a/home/hyprland/waybar/modules/wlr_workspaces.nix +++ b/home/hyprland/waybar/modules/wlr_workspaces.nix @@ -4,16 +4,25 @@ all-outputs = false; format = "{icon}"; format-icons = { - "1" = "󰟀"; - "2" = "󰅴"; - "3" = "󰈹"; - "4" = "󰝰"; - "5" = "󰭹"; - "6" = "󰢹"; - "7" = "󰓓"; - "8" = "󰣘"; - "9" = "󰣙"; - urgent = ""; + "home" = "󰟀"; + "dev" = "󰅴"; + "browser" = "󰈹"; + "files" = "󰝰"; + "chat" = "󰭹"; + "mail" = "󰇮"; + "remote" = "󰢹"; + "steam" = "󰓓"; + "misc" = "󰣙"; + "1" = "󰎤"; + "2" = "󰎧"; + "3" = "󰎪"; + "4" = "󰎭"; + "5" = "󰎱"; + "6" = "󰎳"; + "7" = "󰎶"; + "8" = "󰎹"; + "9" = "󰎼"; + urgent = "󱈸"; }; - sort-by-number = true; + sort-by-name = true; } diff --git a/home/shell/starship.toml b/home/shell/starship.toml index 24a11487..79f0bfda 100644 --- a/home/shell/starship.toml +++ b/home/shell/starship.toml @@ -69,7 +69,7 @@ symbol = " " symbol = "⌘ " [hostname] -ssh_symbol = "󰒋 " +ssh_symbol = "󰢹 " style = "bold green" [hg_branch] diff --git a/hosts/Ronin/home.nix b/hosts/Ronin/home.nix index 81e32892..58683be7 100644 --- a/hosts/Ronin/home.nix +++ b/hosts/Ronin/home.nix @@ -15,6 +15,7 @@ in { inherit username homeDirectory; stateVersion = "22.11"; packages = with pkgs; [ + thunderbird openfortivpn nomachine-client teams-for-linux @@ -34,7 +35,7 @@ in { undocked = { outputs = [ { - criteria = "*"; + criteria = "eDP-1"; status = "enable"; } ]; @@ -48,9 +49,11 @@ in { } { criteria = "Iiyama North America PLB2403WS 0574281251316"; + status = "enable"; } { criteria = "Dell Inc. DELL U2417H 5K9YD872FY1L"; + status = "enable"; } ]; exec = [restart_hyprpaper]; @@ -58,8 +61,8 @@ in { }; }; xdg.configFile."hypr/display.conf".text = '' - monitor=eDP-1,1920x1080@60,auto,1.25 - monitor=desc:Iiyama North America PLB2403WS 0574281251316,1920x1200@60,0x185,1 - monitor=desc:Dell Inc. DELL U2417H 5K9YD872FY1L,1920x1080@60,1920x0,1,transform,1 + monitor=eDP-1,preferred,auto,1.5 + monitor=desc:Iiyama North America PLB2403WS 0574281251316,preferred,0x185,1 + monitor=desc:Dell Inc. DELL U2417H 5K9YD872FY1L,preferred,1920x0,1,transform,1 ''; }