Switch the niri desktop to Noctalia shell
Browse files at this commit0257416862aa876b613465e156dee48ade7cd754Parent: 30989a8- feat
- switch the niri desktop to Noctalia shell
13 changed files +835 -34
- .config/niri/config.kdl +53 -34
- .config/niri/config.kdl.bak +357 -0
- .config/noctalia/bar.toml +37 -0
- .config/noctalia/osd.toml +4 -0
- .config/noctalia/plugins/novpn/novpn.luau +79 -0
- .config/noctalia/plugins/novpn/plugin.toml +17 -0
- .config/noctalia/shell.toml +2 -0
- .config/noctalia/templates.toml +3 -0
- .config/noctalia/widgets.toml +4 -0
- .config/scripts/shared/novpn_apps.sh +63 -0
- .gitignore +3 -0
- .local/state/noctalia/settings.toml +209 -0
- .wezterm.lua +4 -0
.config/niri/config.kdlmodified+53 -34
| @@ -77,11 +77,7 @@ layout { | |||
| 77 | border { | 77 | border { |
| 78 | width 3 | 78 | width 3 |
| 79 | 79 | ||
| 80 | - // WALLUST-GRADIENT | 80 | + // colors come from noctalia.kdl (included at the bottom) |
| 81 | - active-gradient from="#736592" to="#A04006" angle=90 in="oklch" | ||
| 82 | - | ||
| 83 | - inactive-color "#595959aa" | ||
| 84 | - urgent-color "#9b0000" | ||
| 85 | } | 81 | } |
| 86 | 82 | ||
| 87 | } | 83 | } |
| @@ -91,16 +87,18 @@ environment { | |||
| 91 | XCURSOR_SIZE "24" | 87 | XCURSOR_SIZE "24" |
| 92 | } | 88 | } |
| 93 | 89 | ||
| 94 | -spawn-at-startup "sh" "-c" "sleep 1 && /usr/libexec/polkit-mate-authentication-agent-1" | 90 | +// spawn-at-startup "sh" "-c" "sleep 1 && /usr/libexec/polkit-mate-authentication-agent-1" // noctalia is the polkit agent |
| 95 | spawn-at-startup "gsettings" "set" "org.gnome.desktop.interface" "icon-theme" "Papirus-Dark" | 91 | spawn-at-startup "gsettings" "set" "org.gnome.desktop.interface" "icon-theme" "Papirus-Dark" |
| 96 | -spawn-at-startup "sh" "-c" "bash ~/.config/scripts/niri/wallpaper_restore.sh" | 92 | +// spawn-at-startup "sh" "-c" "bash ~/.config/scripts/niri/wallpaper_restore.sh" // noctalia draws the wallpaper |
| 97 | spawn-at-startup "sh" "-c" "bash ~/.config/scripts/shared/song_detail_writer.sh" | 93 | spawn-at-startup "sh" "-c" "bash ~/.config/scripts/shared/song_detail_writer.sh" |
| 98 | -spawn-at-startup "sh" "-c" "sleep 1 && waybar -c ~/.config/waybar/config-niri" | 94 | +// spawn-at-startup "sh" "-c" "sleep 1 && waybar -c ~/.config/waybar/config-niri" // replaced by noctalia |
| 95 | +spawn-at-startup "noctalia" | ||
| 99 | spawn-at-startup "sh" "-c" "sleep 2 && kdeconnect-indicator" | 96 | spawn-at-startup "sh" "-c" "sleep 2 && kdeconnect-indicator" |
| 100 | spawn-at-startup "sh" "-c" "sleep 3 && /opt/Mullvad\\ VPN/mullvad-vpn" | 97 | spawn-at-startup "sh" "-c" "sleep 3 && /opt/Mullvad\\ VPN/mullvad-vpn" |
| 101 | -spawn-at-startup "sh" "-c" "sleep 3 && swaync-client -dn" | 98 | +// spawn-at-startup "sh" "-c" "sleep 3 && swaync-client -dn" // noctalia is the notification daemon |
| 102 | -spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type text --watch cliphist store" | 99 | +// noctalia keeps clipboard history itself |
| 103 | -spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type image --watch cliphist store" | 100 | +// spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type text --watch cliphist store" |
| 101 | +// spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type image --watch cliphist store" | ||
| 104 | spawn-at-startup "sh" "-c" "sleep 4 && rfkill unblock bluetooth && bluetoothctl power on" | 102 | spawn-at-startup "sh" "-c" "sleep 4 && rfkill unblock bluetooth && bluetoothctl power on" |
| 105 | 103 | ||
| 106 | spawn-at-startup "sh" "-c" "sleep 1 && bash ~/.config/scripts/niri/workspace_startup.sh" | 104 | spawn-at-startup "sh" "-c" "sleep 1 && bash ~/.config/scripts/niri/workspace_startup.sh" |
| @@ -127,6 +125,19 @@ window-rule { | |||
| 127 | draw-border-with-background false | 125 | draw-border-with-background false |
| 128 | } | 126 | } |
| 129 | 127 | ||
| 128 | +// Noctalia settings window | ||
| 129 | +window-rule { | ||
| 130 | + match app-id=r#"^dev\.noctalia\.Noctalia$"# | ||
| 131 | + open-floating true | ||
| 132 | + default-column-width { fixed 1080; } | ||
| 133 | + default-window-height { fixed 920; } | ||
| 134 | +} | ||
| 135 | + | ||
| 136 | +debug { | ||
| 137 | + // lets noctalia notification actions activate/focus app windows | ||
| 138 | + honor-xdg-activation-with-invalid-serial | ||
| 139 | +} | ||
| 140 | + | ||
| 130 | workspace "code" { | 141 | workspace "code" { |
| 131 | // hidden // pinned workspaces: not reimplemented in the custom niri build yet | 142 | // hidden // pinned workspaces: not reimplemented in the custom niri build yet |
| 132 | } | 143 | } |
| @@ -152,14 +163,14 @@ binds { | |||
| 152 | Alt+T hotkey-overlay-title="Terminal: wezterm" { spawn-sh "wezterm start --always-new-process"; } | 163 | Alt+T hotkey-overlay-title="Terminal: wezterm" { spawn-sh "wezterm start --always-new-process"; } |
| 153 | Alt+Q hotkey-overlay-title="Files: nautilus" { spawn-sh "nautilus --new-window"; } | 164 | Alt+Q hotkey-overlay-title="Files: nautilus" { spawn-sh "nautilus --new-window"; } |
| 154 | 165 | ||
| 155 | - Alt+F1 hotkey-overlay-title="rofi: window switcher" { spawn-sh "rofi -show"; } | 166 | + Alt+F1 hotkey-overlay-title="Noctalia: window switcher" { spawn-sh "noctalia msg panel-toggle launcher /win"; } |
| 156 | - Alt+1 hotkey-overlay-title="rofi: window switcher" { spawn-sh "rofi -show"; } | 167 | + Alt+1 hotkey-overlay-title="Noctalia: window switcher" { spawn-sh "noctalia msg panel-toggle launcher /win"; } |
| 157 | - Alt+F2 hotkey-overlay-title="rofi: run" { spawn-sh "rofi -show drun -show-icons"; } | 168 | + Alt+F2 hotkey-overlay-title="Noctalia: launcher" { spawn-sh "noctalia msg panel-toggle launcher"; } |
| 158 | - Alt+2 hotkey-overlay-title="rofi: run" { spawn-sh "rofi -show drun -show-icons"; } | 169 | + Alt+2 hotkey-overlay-title="Noctalia: launcher" { spawn-sh "noctalia msg panel-toggle launcher"; } |
| 159 | - Shift+Alt+F2 hotkey-overlay-title="rofi: run (outside VPN)" { spawn-sh "mullvad-exclude rofi -show drun -show-icons"; } | 170 | + Shift+Alt+F2 hotkey-overlay-title="Noctalia: run outside VPN" { spawn-sh "noctalia msg panel-toggle launcher /novpn"; } |
| 160 | - Shift+Alt+2 hotkey-overlay-title="rofi: run (outside VPN)" { spawn-sh "mullvad-exclude rofi -show drun -show-icons"; } | 171 | + Shift+Alt+2 hotkey-overlay-title="Noctalia: run outside VPN" { spawn-sh "noctalia msg panel-toggle launcher /novpn"; } |
| 161 | - Alt+F3 hotkey-overlay-title="Clipboard history" { spawn-sh "cliphist list | rofi -dmenu -show-icons -i | cliphist decode | wl-copy"; } | 172 | + Alt+F3 hotkey-overlay-title="Noctalia: clipboard history" { spawn-sh "noctalia msg panel-toggle clipboard"; } |
| 162 | - Alt+3 hotkey-overlay-title="Clipboard history" { spawn-sh "cliphist list | rofi -dmenu -show-icons -i | cliphist decode | wl-copy"; } | 173 | + Alt+3 hotkey-overlay-title="Noctalia: clipboard history" { spawn-sh "noctalia msg panel-toggle clipboard"; } |
| 163 | 174 | ||
| 164 | Alt+F hotkey-overlay-title="Browser" { spawn-sh "flatpak run io.github.ungoogled_software.ungoogled_chromium --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling"; } | 175 | Alt+F hotkey-overlay-title="Browser" { spawn-sh "flatpak run io.github.ungoogled_software.ungoogled_chromium --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling"; } |
| 165 | Shift+Alt+F hotkey-overlay-title="Browser (incognito, outside VPN)" { spawn-sh "mullvad-exclude flatpak run org.chromium.Chromium --incognito --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling,AllowLegacyMV2Extensions --disable-features=ExtensionManifestV2Unsupported,ExtensionManifestV2Disabled,ExtensionsManifestV3Only"; } | 176 | Shift+Alt+F hotkey-overlay-title="Browser (incognito, outside VPN)" { spawn-sh "mullvad-exclude flatpak run org.chromium.Chromium --incognito --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling,AllowLegacyMV2Extensions --disable-features=ExtensionManifestV2Unsupported,ExtensionManifestV2Disabled,ExtensionsManifestV3Only"; } |
| @@ -187,11 +198,15 @@ binds { | |||
| 187 | Mod+Shift+Y { move-column-to-workspace "youtube"; } | 198 | Mod+Shift+Y { move-column-to-workspace "youtube"; } |
| 188 | Mod+Shift+P { move-column-to-workspace "mail"; } | 199 | Mod+Shift+P { move-column-to-workspace "mail"; } |
| 189 | 200 | ||
| 190 | - Super+L hotkey-overlay-title="Lock: hyprlock" { spawn "hyprlock"; } | 201 | + Mod+Space hotkey-overlay-title="Noctalia: launcher" { spawn-sh "noctalia msg panel-toggle launcher"; } |
| 191 | - Mod+Escape hotkey-overlay-title="Power menu" { spawn-sh "bash ~/.config/scripts/system/power_menu.sh"; } | 202 | + Mod+N hotkey-overlay-title="Noctalia: control center" { spawn-sh "noctalia msg panel-toggle control-center"; } |
| 203 | + Mod+Shift+Comma hotkey-overlay-title="Noctalia: settings" { spawn-sh "noctalia msg settings-toggle"; } | ||
| 204 | + | ||
| 205 | + Super+L hotkey-overlay-title="Lock: noctalia" { spawn-sh "noctalia msg session lock"; } | ||
| 206 | + Mod+Escape hotkey-overlay-title="Power menu" { spawn-sh "noctalia msg panel-toggle session"; } | ||
| 192 | Mod+X hotkey-overlay-title="Show desktop" { spawn-sh "~/.config/scripts/niri/show_desktop.sh"; } | 207 | Mod+X hotkey-overlay-title="Show desktop" { spawn-sh "~/.config/scripts/niri/show_desktop.sh"; } |
| 193 | - Mod+H hotkey-overlay-title="Toggle waybar" { spawn-sh "pkill -SIGUSR1 waybar"; } | 208 | + Mod+H hotkey-overlay-title="Toggle bar" { spawn-sh "noctalia msg bar-toggle"; } |
| 194 | - Mod+B hotkey-overlay-title="Wallpaper picker" { spawn-sh "~/.config/scripts/niri/wallpaper_picker.sh"; } | 209 | + Mod+B hotkey-overlay-title="Noctalia: wallpaper picker" { spawn-sh "noctalia msg panel-toggle wallpaper"; } |
| 195 | Mod+Shift+M hotkey-overlay-title="Monitors menu" { spawn-sh "~/.config/scripts/niri/toggle_monitors.sh"; } | 210 | Mod+Shift+M hotkey-overlay-title="Monitors menu" { spawn-sh "~/.config/scripts/niri/toggle_monitors.sh"; } |
| 196 | Mod+Shift+K hotkey-overlay-title="USB plug/unplug menu" { spawn-sh "bash ~/.config/scripts/system/usb_menu.sh"; } | 211 | Mod+Shift+K hotkey-overlay-title="USB plug/unplug menu" { spawn-sh "bash ~/.config/scripts/system/usb_menu.sh"; } |
| 197 | Mod+Ctrl+M hotkey-overlay-title="Wake monitors" { power-on-monitors; } | 212 | Mod+Ctrl+M hotkey-overlay-title="Wake monitors" { power-on-monitors; } |
| @@ -205,19 +220,21 @@ binds { | |||
| 205 | Mod+O repeat=false { toggle-overview; } | 220 | Mod+O repeat=false { toggle-overview; } |
| 206 | // Super+Alt+S allow-when-locked=true hotkey-overlay-title=null { spawn-sh "pkill orca || exec orca"; } | 221 | // Super+Alt+S allow-when-locked=true hotkey-overlay-title=null { spawn-sh "pkill orca || exec orca"; } |
| 207 | 222 | ||
| 208 | - XF86AudioRaiseVolume allow-when-locked=true { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1+ -l 1.0"; } | 223 | + XF86AudioRaiseVolume allow-when-locked=true { spawn-sh "noctalia msg volume-up"; } |
| 209 | - XF86AudioLowerVolume allow-when-locked=true { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1-"; } | 224 | + XF86AudioLowerVolume allow-when-locked=true { spawn-sh "noctalia msg volume-down"; } |
| 210 | - XF86AudioMute allow-when-locked=true { spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"; } | 225 | + XF86AudioMute allow-when-locked=true { spawn-sh "noctalia msg volume-mute"; } |
| 211 | - XF86AudioMicMute allow-when-locked=true { spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"; } | 226 | + XF86AudioMicMute allow-when-locked=true { spawn-sh "noctalia msg mic-mute"; } |
| 212 | - XF86AudioPlay allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh play-pause"; } | 227 | + XF86AudioPlay allow-when-locked=true { spawn-sh "noctalia msg media toggle"; } |
| 213 | - XF86AudioStop allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh pause"; } | 228 | + XF86AudioStop allow-when-locked=true { spawn-sh "noctalia msg media stop"; } |
| 214 | - XF86AudioPrev allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh previous"; } | 229 | + XF86AudioPrev allow-when-locked=true { spawn-sh "noctalia msg media previous"; } |
| 215 | - XF86AudioNext allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh next"; } | 230 | + XF86AudioNext allow-when-locked=true { spawn-sh "noctalia msg media next"; } |
| 216 | - XF86MonBrightnessUp allow-when-locked=true { spawn "brightnessctl" "--class=backlight" "set" "+10%"; } | 231 | + XF86MonBrightnessUp allow-when-locked=true { spawn-sh "noctalia msg brightness-up"; } |
| 217 | - XF86MonBrightnessDown allow-when-locked=true { spawn "brightnessctl" "--class=backlight" "set" "10%-"; } | 232 | + XF86MonBrightnessDown allow-when-locked=true { spawn-sh "noctalia msg brightness-down"; } |
| 218 | 233 | ||
| 219 | Print { spawn-sh "grim -t png - | tee \"$HOME/Pictures/Screenshots/$(date '+%y%m%d_%H-%M-%S').png\" | wl-copy -t image/png"; } | 234 | Print { spawn-sh "grim -t png - | tee \"$HOME/Pictures/Screenshots/$(date '+%y%m%d_%H-%M-%S').png\" | wl-copy -t image/png"; } |
| 235 | + // region: clipboard only, never saved | ||
| 220 | Shift+Print { spawn-sh "grim -t png -g \"$(slurp)\" - | wl-copy -t image/png"; } | 236 | Shift+Print { spawn-sh "grim -t png -g \"$(slurp)\" - | wl-copy -t image/png"; } |
| 237 | + Mod+Print { spawn-sh "noctalia msg screenshot-annotate"; } | ||
| 221 | Ctrl+Print { screenshot-screen; } | 238 | Ctrl+Print { screenshot-screen; } |
| 222 | Alt+Print { screenshot-window; } | 239 | Alt+Print { screenshot-window; } |
| 223 | 240 | ||
| @@ -250,7 +267,7 @@ binds { | |||
| 250 | Mod+Home { focus-column-first; } | 267 | Mod+Home { focus-column-first; } |
| 251 | Mod+End { focus-column-last; } | 268 | Mod+End { focus-column-last; } |
| 252 | Mod+Tab { focus-window-previous; } | 269 | Mod+Tab { focus-window-previous; } |
| 253 | - Alt+Tab { focus-workspace-previous; } | 270 | + // Alt+Tab / Alt+Shift+Tab left unbound: niri's built-in recent-windows switcher (live previews) |
| 254 | 271 | ||
| 255 | // Left-hand WASD moving | 272 | // Left-hand WASD moving |
| 256 | Mod+Ctrl+A { move-column-left-or-to-monitor-left; } | 273 | Mod+Ctrl+A { move-column-left-or-to-monitor-left; } |
| @@ -355,3 +372,5 @@ binds { | |||
| 355 | Mod+Period { expel-window-from-column; } | 372 | Mod+Period { expel-window-from-column; } |
| 356 | Mod+Ctrl+T { toggle-column-tabbed-display; } | 373 | Mod+Ctrl+T { toggle-column-tabbed-display; } |
| 357 | } | 374 | } |
| 375 | + | ||
| 376 | +include "noctalia.kdl" | ||
.config/niri/config.kdl.bakadded+357 -0
| @@ -0,0 +1,357 @@ | |||
| 1 | + | ||
| 2 | +hotkey-overlay { | ||
| 3 | + skip-at-startup | ||
| 4 | +} | ||
| 5 | + | ||
| 6 | +input { | ||
| 7 | + keyboard { | ||
| 8 | + xkb { | ||
| 9 | + layout "tr"; | ||
| 10 | + } | ||
| 11 | + numlock | ||
| 12 | + } | ||
| 13 | + | ||
| 14 | + touchpad { | ||
| 15 | + tap | ||
| 16 | + natural-scroll | ||
| 17 | + } | ||
| 18 | + | ||
| 19 | + mouse { | ||
| 20 | + accel-profile "flat" | ||
| 21 | + } | ||
| 22 | + | ||
| 23 | + trackpoint { | ||
| 24 | + } | ||
| 25 | + | ||
| 26 | + wake-monitors-on-input false | ||
| 27 | +} | ||
| 28 | + | ||
| 29 | +prefer-no-csd | ||
| 30 | + | ||
| 31 | +gestures { | ||
| 32 | + hot-corners { | ||
| 33 | + off | ||
| 34 | + } | ||
| 35 | +} | ||
| 36 | + | ||
| 37 | +output "DP-1" { | ||
| 38 | + mode "2560x1440@180" | ||
| 39 | + scale 1 | ||
| 40 | + transform "normal" | ||
| 41 | + position x=0 y=0 | ||
| 42 | + focus-at-startup | ||
| 43 | +} | ||
| 44 | + | ||
| 45 | +output "HDMI-A-1" { | ||
| 46 | + mode "1920x1080@75.003" | ||
| 47 | + scale 1 | ||
| 48 | + transform "normal" | ||
| 49 | + position x=2560 y=0 | ||
| 50 | +} | ||
| 51 | + | ||
| 52 | +layout { | ||
| 53 | + gaps 3 | ||
| 54 | + struts { | ||
| 55 | + left 7 | ||
| 56 | + right 7 | ||
| 57 | + top 7 | ||
| 58 | + bottom 7 | ||
| 59 | + } | ||
| 60 | + | ||
| 61 | + center-focused-column "never" | ||
| 62 | + | ||
| 63 | + empty-workspace-above-first | ||
| 64 | + | ||
| 65 | + default-column-width { proportion 0.5; } | ||
| 66 | + preset-column-widths { | ||
| 67 | + proportion 0.33333 | ||
| 68 | + proportion 0.5 | ||
| 69 | + proportion 0.66667 | ||
| 70 | + proportion 1.0 | ||
| 71 | + } | ||
| 72 | + | ||
| 73 | + focus-ring { | ||
| 74 | + off | ||
| 75 | + } | ||
| 76 | + | ||
| 77 | + border { | ||
| 78 | + width 3 | ||
| 79 | + | ||
| 80 | + // WALLUST-GRADIENT | ||
| 81 | + active-gradient from="#B67A8D" to="#D99239" angle=90 in="oklch" | ||
| 82 | + | ||
| 83 | + inactive-color "#595959aa" | ||
| 84 | + urgent-color "#9b0000" | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | +} | ||
| 88 | + | ||
| 89 | +environment { | ||
| 90 | + QT_QPA_PLATFORMTHEME "qt6ct" | ||
| 91 | + XCURSOR_SIZE "24" | ||
| 92 | +} | ||
| 93 | + | ||
| 94 | +spawn-at-startup "sh" "-c" "sleep 1 && /usr/libexec/polkit-mate-authentication-agent-1" | ||
| 95 | +spawn-at-startup "gsettings" "set" "org.gnome.desktop.interface" "icon-theme" "Papirus-Dark" | ||
| 96 | +spawn-at-startup "sh" "-c" "bash ~/.config/scripts/niri/wallpaper_restore.sh" | ||
| 97 | +spawn-at-startup "sh" "-c" "bash ~/.config/scripts/shared/song_detail_writer.sh" | ||
| 98 | +spawn-at-startup "sh" "-c" "sleep 1 && waybar -c ~/.config/waybar/config-niri" | ||
| 99 | +spawn-at-startup "sh" "-c" "sleep 2 && kdeconnect-indicator" | ||
| 100 | +spawn-at-startup "sh" "-c" "sleep 3 && /opt/Mullvad\\ VPN/mullvad-vpn" | ||
| 101 | +spawn-at-startup "sh" "-c" "sleep 3 && swaync-client -dn" | ||
| 102 | +spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type text --watch cliphist store" | ||
| 103 | +spawn-at-startup "sh" "-c" "sleep 3 && wl-paste --type image --watch cliphist store" | ||
| 104 | +spawn-at-startup "sh" "-c" "sleep 4 && rfkill unblock bluetooth && bluetoothctl power on" | ||
| 105 | + | ||
| 106 | +spawn-at-startup "sh" "-c" "sleep 1 && bash ~/.config/scripts/niri/workspace_startup.sh" | ||
| 107 | + | ||
| 108 | +screenshot-path "~/Pictures/Screenshots/Screenshot from %Y-%m-%d %H-%M-%S.png" | ||
| 109 | + | ||
| 110 | +animations { | ||
| 111 | +} | ||
| 112 | + | ||
| 113 | +window-rule { | ||
| 114 | + // background fill in border color: the border's inner AA edge and the app's | ||
| 115 | + // corner AA edge share a line; without the fill the backdrop bleeds through | ||
| 116 | + // that seam. Transparent apps opt back out per-rule (wezterm below). | ||
| 117 | + draw-border-with-background true | ||
| 118 | + // libadwaita 1.6+ draws 15; must stay >= the largest toolkit radius so | ||
| 119 | + // clip-to-geometry dominates and the border hugs every corner. 16 = 1px margin. | ||
| 120 | + geometry-corner-radius 16 | ||
| 121 | + clip-to-geometry true | ||
| 122 | +} | ||
| 123 | + | ||
| 124 | +window-rule { | ||
| 125 | + match app-id=r#"^org\.wezfurlong\.wezterm$"# | ||
| 126 | + opacity 0.8 | ||
| 127 | + draw-border-with-background false | ||
| 128 | +} | ||
| 129 | + | ||
| 130 | +workspace "code" { | ||
| 131 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 132 | +} | ||
| 133 | +workspace "github" { | ||
| 134 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 135 | +} | ||
| 136 | +workspace "whatsapp" { | ||
| 137 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 138 | +} | ||
| 139 | +workspace "discord" { | ||
| 140 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 141 | +} | ||
| 142 | +workspace "deezer" { | ||
| 143 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 144 | +} | ||
| 145 | +workspace "youtube" { | ||
| 146 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 147 | +} | ||
| 148 | +workspace "mail" { | ||
| 149 | + // hidden // pinned workspaces: not reimplemented in the custom niri build yet | ||
| 150 | +} | ||
| 151 | +binds { | ||
| 152 | + Alt+T hotkey-overlay-title="Terminal: wezterm" { spawn-sh "wezterm start --always-new-process"; } | ||
| 153 | + Alt+Q hotkey-overlay-title="Files: nautilus" { spawn-sh "nautilus --new-window"; } | ||
| 154 | + | ||
| 155 | + Alt+F1 hotkey-overlay-title="rofi: window switcher" { spawn-sh "rofi -show"; } | ||
| 156 | + Alt+1 hotkey-overlay-title="rofi: window switcher" { spawn-sh "rofi -show"; } | ||
| 157 | + Alt+F2 hotkey-overlay-title="rofi: run" { spawn-sh "rofi -show drun -show-icons"; } | ||
| 158 | + Alt+2 hotkey-overlay-title="rofi: run" { spawn-sh "rofi -show drun -show-icons"; } | ||
| 159 | + Shift+Alt+F2 hotkey-overlay-title="rofi: run (outside VPN)" { spawn-sh "mullvad-exclude rofi -show drun -show-icons"; } | ||
| 160 | + Shift+Alt+2 hotkey-overlay-title="rofi: run (outside VPN)" { spawn-sh "mullvad-exclude rofi -show drun -show-icons"; } | ||
| 161 | + Alt+F3 hotkey-overlay-title="Clipboard history" { spawn-sh "cliphist list | rofi -dmenu -show-icons -i | cliphist decode | wl-copy"; } | ||
| 162 | + Alt+3 hotkey-overlay-title="Clipboard history" { spawn-sh "cliphist list | rofi -dmenu -show-icons -i | cliphist decode | wl-copy"; } | ||
| 163 | + | ||
| 164 | + Alt+F hotkey-overlay-title="Browser" { spawn-sh "flatpak run io.github.ungoogled_software.ungoogled_chromium --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling"; } | ||
| 165 | + Shift+Alt+F hotkey-overlay-title="Browser (incognito, outside VPN)" { spawn-sh "mullvad-exclude flatpak run org.chromium.Chromium --incognito --enable-features=MiddleClickAutoscroll,HardwareMediaKeyHandling,AllowLegacyMV2Extensions --disable-features=ExtensionManifestV2Unsupported,ExtensionManifestV2Disabled,ExtensionsManifestV3Only"; } | ||
| 166 | + | ||
| 167 | + Alt+C hotkey-overlay-title="Workspace: code" { focus-workspace "code"; } | ||
| 168 | + Alt+G hotkey-overlay-title="Workspace: github" { focus-workspace "github"; } | ||
| 169 | + Alt+W hotkey-overlay-title="Workspace: whatsapp" { focus-workspace "whatsapp"; } | ||
| 170 | + Alt+D hotkey-overlay-title="Workspace: discord" { focus-workspace "discord"; } | ||
| 171 | + Alt+S hotkey-overlay-title="Workspace: deezer" { focus-workspace "deezer"; } | ||
| 172 | + Alt+Y hotkey-overlay-title="Workspace: youtube" { focus-workspace "youtube"; } | ||
| 173 | + Alt+P hotkey-overlay-title="Workspace: mail" { focus-workspace "mail"; } | ||
| 174 | + Shift+Alt+C hotkey-overlay-title="Launch: zed" { spawn-sh "zed"; } | ||
| 175 | + Shift+Alt+G hotkey-overlay-title="Launch: github" { spawn-sh "~/.config/scripts/shared/webapp.sh https://github.com/ FCF18Wmt"; } | ||
| 176 | + Shift+Alt+W hotkey-overlay-title="Launch: whatsapp" { spawn-sh "~/.config/scripts/shared/webapp.sh --mullvad https://web.whatsapp.com/ aW2IMaZ8"; } | ||
| 177 | + Shift+Alt+D hotkey-overlay-title="Launch: discord" { spawn-sh "flatpak run org.equicord.equibop"; } | ||
| 178 | + Shift+Alt+S hotkey-overlay-title="Launch: deezer" { spawn-sh "~/.config/scripts/shared/webapp.sh --mullvad https://deezer.com/ VjW8vTQ3"; } | ||
| 179 | + Shift+Alt+Y hotkey-overlay-title="Launch: youtube" { spawn-sh "mullvad-exclude flatpak run --command=bash io.freetubeapp.FreeTube -c 'true & wait; run.sh; exit $?'"; } | ||
| 180 | + Shift+Alt+P hotkey-overlay-title="Launch: mail" { spawn-sh "~/.config/scripts/shared/webapp.sh https://mail.proton.me/ eIpzVtL8"; } | ||
| 181 | + | ||
| 182 | + Mod+Shift+C { move-column-to-workspace "code"; } | ||
| 183 | + Mod+Shift+G { move-column-to-workspace "github"; } | ||
| 184 | + Mod+Shift+W { move-column-to-workspace "whatsapp"; } | ||
| 185 | + Mod+Shift+D { move-column-to-workspace "discord"; } | ||
| 186 | + Mod+Shift+S { move-column-to-workspace "deezer"; } | ||
| 187 | + Mod+Shift+Y { move-column-to-workspace "youtube"; } | ||
| 188 | + Mod+Shift+P { move-column-to-workspace "mail"; } | ||
| 189 | + | ||
| 190 | + Super+L hotkey-overlay-title="Lock: hyprlock" { spawn "hyprlock"; } | ||
| 191 | + Mod+Escape hotkey-overlay-title="Power menu" { spawn-sh "bash ~/.config/scripts/system/power_menu.sh"; } | ||
| 192 | + Mod+X hotkey-overlay-title="Show desktop" { spawn-sh "~/.config/scripts/niri/show_desktop.sh"; } | ||
| 193 | + Mod+H hotkey-overlay-title="Toggle waybar" { spawn-sh "pkill -SIGUSR1 waybar"; } | ||
| 194 | + Mod+B hotkey-overlay-title="Wallpaper picker" { spawn-sh "~/.config/scripts/niri/wallpaper_picker.sh"; } | ||
| 195 | + Mod+Shift+M hotkey-overlay-title="Monitors menu" { spawn-sh "~/.config/scripts/niri/toggle_monitors.sh"; } | ||
| 196 | + Mod+Shift+K hotkey-overlay-title="USB plug/unplug menu" { spawn-sh "bash ~/.config/scripts/system/usb_menu.sh"; } | ||
| 197 | + Mod+Ctrl+M hotkey-overlay-title="Wake monitors" { power-on-monitors; } | ||
| 198 | + | ||
| 199 | + Alt+4 repeat=false { close-window; } | ||
| 200 | + Alt+F4 repeat=false { close-window; } | ||
| 201 | + Mod+Alt+F4 { quit; } | ||
| 202 | + | ||
| 203 | + Mod+Shift+Escape allow-inhibiting=false { toggle-keyboard-shortcuts-inhibit; } | ||
| 204 | + Mod+Shift+Slash { show-hotkey-overlay; } | ||
| 205 | + Mod+O repeat=false { toggle-overview; } | ||
| 206 | + // Super+Alt+S allow-when-locked=true hotkey-overlay-title=null { spawn-sh "pkill orca || exec orca"; } | ||
| 207 | + | ||
| 208 | + XF86AudioRaiseVolume allow-when-locked=true { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1+ -l 1.0"; } | ||
| 209 | + XF86AudioLowerVolume allow-when-locked=true { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1-"; } | ||
| 210 | + XF86AudioMute allow-when-locked=true { spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"; } | ||
| 211 | + XF86AudioMicMute allow-when-locked=true { spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"; } | ||
| 212 | + XF86AudioPlay allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh play-pause"; } | ||
| 213 | + XF86AudioStop allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh pause"; } | ||
| 214 | + XF86AudioPrev allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh previous"; } | ||
| 215 | + XF86AudioNext allow-when-locked=true { spawn-sh "~/.config/scripts/shared/playerctl_active.sh next"; } | ||
| 216 | + XF86MonBrightnessUp allow-when-locked=true { spawn "brightnessctl" "--class=backlight" "set" "+10%"; } | ||
| 217 | + XF86MonBrightnessDown allow-when-locked=true { spawn "brightnessctl" "--class=backlight" "set" "10%-"; } | ||
| 218 | + | ||
| 219 | + Print { spawn-sh "grim -t png - | tee \"$HOME/Pictures/Screenshots/$(date '+%y%m%d_%H-%M-%S').png\" | wl-copy -t image/png"; } | ||
| 220 | + Shift+Print { spawn-sh "grim -t png -g \"$(slurp)\" - | wl-copy -t image/png"; } | ||
| 221 | + Ctrl+Print { screenshot-screen; } | ||
| 222 | + Alt+Print { screenshot-window; } | ||
| 223 | + | ||
| 224 | + Mod+Q { focus-monitor "DP-1"; } | ||
| 225 | + Mod+E { focus-monitor "HDMI-A-1"; } | ||
| 226 | + Mod+Shift+Q { move-column-to-monitor "DP-1"; } | ||
| 227 | + Mod+Shift+E { move-column-to-monitor "HDMI-A-1"; } | ||
| 228 | + Mod+Ctrl+Shift+A hotkey-overlay-title="Move workspace left" { move-workspace-to-monitor-left; } | ||
| 229 | + Mod+Ctrl+Shift+D hotkey-overlay-title="Move workspace right" { move-workspace-to-monitor-right; } | ||
| 230 | + Mod+Ctrl+Shift+W hotkey-overlay-title="Move workspace up" { move-workspace-to-monitor-up; } | ||
| 231 | + Mod+Ctrl+Shift+S hotkey-overlay-title="Move workspace down" { move-workspace-to-monitor-down; } | ||
| 232 | + Mod+Ctrl+Shift+Left { move-workspace-to-monitor-left; } | ||
| 233 | + Mod+Ctrl+Shift+Right { move-workspace-to-monitor-right; } | ||
| 234 | + Mod+Ctrl+Shift+Up { move-workspace-to-monitor-up; } | ||
| 235 | + Mod+Ctrl+Shift+Down { move-workspace-to-monitor-down; } | ||
| 236 | + | ||
| 237 | + | ||
| 238 | + // Left-hand WASD navigation (right hand stays on mouse) | ||
| 239 | + Mod+A { focus-column-or-monitor-left; } | ||
| 240 | + Mod+D { focus-column-or-monitor-right; } | ||
| 241 | + Mod+W { focus-workspace-up; } | ||
| 242 | + Mod+S { focus-workspace-down; } | ||
| 243 | + | ||
| 244 | + Mod+Left { focus-column-left; } | ||
| 245 | + Mod+Right { focus-column-right; } | ||
| 246 | + Mod+Up { focus-workspace-up; } | ||
| 247 | + Mod+Down { focus-workspace-down; } | ||
| 248 | + Mod+J { focus-window-down; } | ||
| 249 | + Mod+K { focus-window-up; } | ||
| 250 | + Mod+Home { focus-column-first; } | ||
| 251 | + Mod+End { focus-column-last; } | ||
| 252 | + Mod+Tab { focus-window-previous; } | ||
| 253 | + Alt+Tab { focus-workspace-previous; } | ||
| 254 | + | ||
| 255 | + // Left-hand WASD moving | ||
| 256 | + Mod+Ctrl+A { move-column-left-or-to-monitor-left; } | ||
| 257 | + Mod+Ctrl+D { move-column-right-or-to-monitor-right; } | ||
| 258 | + Mod+Ctrl+W { move-column-to-workspace-up; } | ||
| 259 | + Mod+Ctrl+S { move-column-to-workspace-down; } | ||
| 260 | + | ||
| 261 | + Mod+Ctrl+Left { move-column-left; } | ||
| 262 | + Mod+Ctrl+Right { move-column-right; } | ||
| 263 | + Mod+Ctrl+Up { move-column-to-workspace-up; } | ||
| 264 | + Mod+Ctrl+Down { move-column-to-workspace-down; } | ||
| 265 | + Mod+Ctrl+H { move-column-left; } | ||
| 266 | + Mod+Ctrl+L { move-column-right; } | ||
| 267 | + Mod+Ctrl+J { move-window-down; } | ||
| 268 | + Mod+Ctrl+K { move-window-up; } | ||
| 269 | + Mod+Ctrl+Home { move-column-to-first; } | ||
| 270 | + Mod+Ctrl+End { move-column-to-last; } | ||
| 271 | + | ||
| 272 | + Mod+1 { focus-workspace 1; } | ||
| 273 | + Mod+2 { focus-workspace 2; } | ||
| 274 | + Mod+3 { focus-workspace 3; } | ||
| 275 | + Mod+4 { focus-workspace 4; } | ||
| 276 | + Mod+5 { focus-workspace 5; } | ||
| 277 | + Mod+6 { focus-workspace 6; } | ||
| 278 | + Mod+7 { focus-workspace 7; } | ||
| 279 | + Mod+8 { focus-workspace 8; } | ||
| 280 | + Mod+9 { focus-workspace 9; } | ||
| 281 | + Mod+0 { focus-workspace 10; } | ||
| 282 | + | ||
| 283 | + Mod+Shift+1 { move-column-to-workspace 1; } | ||
| 284 | + Mod+Shift+2 { move-column-to-workspace 2; } | ||
| 285 | + Mod+Shift+3 { move-column-to-workspace 3; } | ||
| 286 | + Mod+Shift+4 { move-column-to-workspace 4; } | ||
| 287 | + Mod+Shift+5 { move-column-to-workspace 5; } | ||
| 288 | + Mod+Shift+6 { move-column-to-workspace 6; } | ||
| 289 | + Mod+Shift+7 { move-column-to-workspace 7; } | ||
| 290 | + Mod+Shift+8 { move-column-to-workspace 8; } | ||
| 291 | + Mod+Shift+9 { move-column-to-workspace 9; } | ||
| 292 | + Mod+Shift+0 { move-column-to-workspace 10; } | ||
| 293 | + | ||
| 294 | + Mod+Ctrl+1 { move-column-to-workspace 1; } | ||
| 295 | + Mod+Ctrl+2 { move-column-to-workspace 2; } | ||
| 296 | + Mod+Ctrl+3 { move-column-to-workspace 3; } | ||
| 297 | + Mod+Ctrl+4 { move-column-to-workspace 4; } | ||
| 298 | + Mod+Ctrl+5 { move-column-to-workspace 5; } | ||
| 299 | + Mod+Ctrl+6 { move-column-to-workspace 6; } | ||
| 300 | + Mod+Ctrl+7 { move-column-to-workspace 7; } | ||
| 301 | + Mod+Ctrl+8 { move-column-to-workspace 8; } | ||
| 302 | + Mod+Ctrl+9 { move-column-to-workspace 9; } | ||
| 303 | + | ||
| 304 | + Mod+Page_Down { focus-workspace-down; } | ||
| 305 | + Mod+Page_Up { focus-workspace-up; } | ||
| 306 | + Mod+U { focus-workspace-down; } | ||
| 307 | + Mod+I { focus-workspace-up; } | ||
| 308 | + Mod+Ctrl+Page_Down { move-column-to-workspace-down; } | ||
| 309 | + Mod+Ctrl+Page_Up { move-column-to-workspace-up; } | ||
| 310 | + Mod+Ctrl+U { move-column-to-workspace-down; } | ||
| 311 | + Mod+Ctrl+I { move-column-to-workspace-up; } | ||
| 312 | + Mod+Shift+Page_Down { move-workspace-down; } | ||
| 313 | + Mod+Shift+Page_Up { move-workspace-up; } | ||
| 314 | + Mod+Shift+U { move-workspace-down; } | ||
| 315 | + Mod+Shift+I { move-workspace-up; } | ||
| 316 | + | ||
| 317 | + Mod+WheelScrollDown cooldown-ms=150 { focus-workspace-down; } | ||
| 318 | + Mod+WheelScrollUp cooldown-ms=150 { focus-workspace-up; } | ||
| 319 | + Mod+Ctrl+WheelScrollDown cooldown-ms=150 { move-column-to-workspace-down; } | ||
| 320 | + Mod+Ctrl+WheelScrollUp cooldown-ms=150 { move-column-to-workspace-up; } | ||
| 321 | + Mod+WheelScrollRight { focus-column-right; } | ||
| 322 | + Mod+WheelScrollLeft { focus-column-left; } | ||
| 323 | + Mod+Ctrl+WheelScrollRight { move-column-right; } | ||
| 324 | + Mod+Ctrl+WheelScrollLeft { move-column-left; } | ||
| 325 | + Mod+Shift+WheelScrollDown { focus-column-right; } | ||
| 326 | + Mod+Shift+WheelScrollUp { focus-column-left; } | ||
| 327 | + Mod+Ctrl+Shift+WheelScrollDown { move-column-right; } | ||
| 328 | + Mod+Ctrl+Shift+WheelScrollUp { move-column-left; } | ||
| 329 | + | ||
| 330 | + Mod+F { toggle-window-floating; } | ||
| 331 | + Mod+Shift+F { fullscreen-window; } | ||
| 332 | + Mod+M { maximize-column; } | ||
| 333 | + Mod+Ctrl+F { expand-column-to-available-width; } | ||
| 334 | + Mod+Shift+V { switch-focus-between-floating-and-tiling; } | ||
| 335 | + | ||
| 336 | + Mod+Shift+Right { set-column-width "+30"; } | ||
| 337 | + Mod+Shift+Left { set-column-width "-30"; } | ||
| 338 | + Mod+Shift+Up { set-window-height "-30"; } | ||
| 339 | + Mod+Shift+Down { set-window-height "+30"; } | ||
| 340 | + Mod+Minus { set-column-width "-10%"; } | ||
| 341 | + Mod+Equal { set-column-width "+10%"; } | ||
| 342 | + Mod+Shift+Minus { set-window-height "-10%"; } | ||
| 343 | + Mod+Shift+Equal { set-window-height "+10%"; } | ||
| 344 | + | ||
| 345 | + Mod+R { switch-preset-column-width; } | ||
| 346 | + Mod+Shift+R { switch-preset-column-width-back; } | ||
| 347 | + Mod+Ctrl+R { reset-window-height; } | ||
| 348 | + Mod+Ctrl+Shift+R { switch-preset-window-height; } | ||
| 349 | + | ||
| 350 | + Mod+C { center-column; } | ||
| 351 | + Mod+Ctrl+C { center-visible-columns; } | ||
| 352 | + Mod+BracketLeft { consume-or-expel-window-left; } | ||
| 353 | + Mod+BracketRight { consume-or-expel-window-right; } | ||
| 354 | + Mod+Comma { consume-window-into-column; } | ||
| 355 | + Mod+Period { expel-window-from-column; } | ||
| 356 | + Mod+Ctrl+T { toggle-column-tabbed-display; } | ||
| 357 | +} | ||
.config/noctalia/bar.tomladded+37 -0
| @@ -0,0 +1,37 @@ | |||
| 1 | +[bar.default] | ||
| 2 | +background_opacity = 0.9 | ||
| 3 | +margin_ends = 500 | ||
| 4 | +start = ["workspaces", "gap", "media"] | ||
| 5 | +end = [ | ||
| 6 | + "sysmon", | ||
| 7 | + "privacy", | ||
| 8 | + "tray", | ||
| 9 | + "volume", | ||
| 10 | + "brightness", | ||
| 11 | + "battery", | ||
| 12 | +] | ||
| 13 | + | ||
| 14 | +# tray icons collapse behind one button; click it to open the drawer | ||
| 15 | +[widget.tray] | ||
| 16 | +drawer = true | ||
| 17 | + | ||
| 18 | +# hide when no player is open | ||
| 19 | +[widget.media] | ||
| 20 | +hide_when_no_media = true | ||
| 21 | +rotate_album_art = true | ||
| 22 | +title_scroll = "on_hover" | ||
| 23 | +max_length = 350 | ||
| 24 | + | ||
| 25 | +# only show while mic/camera/screen is in use | ||
| 26 | +[widget.privacy] | ||
| 27 | +hide_inactive = true | ||
| 28 | + | ||
| 29 | +# space between workspaces and media | ||
| 30 | +[widget.gap] | ||
| 31 | +type = "spacer" | ||
| 32 | +length = 24 | ||
| 33 | + | ||
| 34 | +# HDMI is smaller, so keep its bar wider than DP-1's | ||
| 35 | +[bar.default.monitor.hdmi] | ||
| 36 | +match = "HDMI-A-1" | ||
| 37 | +margin_ends = 250 | ||
.config/noctalia/osd.tomladded+4 -0
| @@ -0,0 +1,4 @@ | |||
| 1 | +[osd] | ||
| 2 | +position = "top_right" | ||
| 3 | +hide_delay_ms = 800 | ||
| 4 | +scale = 0.8 | ||
.config/noctalia/plugins/novpn/novpn.luauadded+79 -0
| @@ -0,0 +1,79 @@ | |||
| 1 | +--!nonstrict | ||
| 2 | +-- Outside-VPN launcher provider. | ||
| 3 | +-- | ||
| 4 | +-- Type `/novpn` in the launcher (Shift+Alt+2) to list desktop apps with their | ||
| 5 | +-- own icons and descriptions; Enter starts the app under mullvad-exclude. | ||
| 6 | +-- App discovery and launching live in ~/.config/scripts/shared/novpn_apps.sh. | ||
| 7 | + | ||
| 8 | +local SCRIPT = "$HOME/.config/scripts/shared/novpn_apps.sh" | ||
| 9 | + | ||
| 10 | +-- nil until the first list arrives; rescanned whenever the menu opens (empty query) | ||
| 11 | +-- so new installs show up, but not on every keystroke. | ||
| 12 | +local apps = nil | ||
| 13 | +local lastQuery = "" | ||
| 14 | + | ||
| 15 | +local function parse(stdout) | ||
| 16 | + local list = {} | ||
| 17 | + for line in stdout:gmatch("[^\n]+") do | ||
| 18 | + local name, desc, icon, path = line:match("^([^\t]*)\t([^\t]*)\t([^\t]*)\t(.+)$") | ||
| 19 | + if name and path then | ||
| 20 | + table.insert(list, { name = name, desc = desc, icon = icon, path = path }) | ||
| 21 | + end | ||
| 22 | + end | ||
| 23 | + return list | ||
| 24 | +end | ||
| 25 | + | ||
| 26 | +local function publish(query) | ||
| 27 | + if not apps then | ||
| 28 | + launcher.setResults(query, { | ||
| 29 | + { id = "", title = "Loading apps…", glyph = "loader" }, | ||
| 30 | + }) | ||
| 31 | + return | ||
| 32 | + end | ||
| 33 | + | ||
| 34 | + local text = noctalia.string.trim(query) | ||
| 35 | + local rows = {} | ||
| 36 | + for _, app in apps do | ||
| 37 | + local score = 0 | ||
| 38 | + if text ~= "" then | ||
| 39 | + score = noctalia.fuzzyScore(text, app.name) | ||
| 40 | + end | ||
| 41 | + if score then | ||
| 42 | + table.insert(rows, { | ||
| 43 | + id = app.path, | ||
| 44 | + title = app.name, | ||
| 45 | + subtitle = if app.desc ~= "" then app.desc else nil, | ||
| 46 | + icon = if app.icon ~= "" then app.icon else nil, | ||
| 47 | + glyph = "shield-off", | ||
| 48 | + score = score, | ||
| 49 | + }) | ||
| 50 | + end | ||
| 51 | + end | ||
| 52 | + | ||
| 53 | + if #rows == 0 then | ||
| 54 | + rows[1] = { id = "", title = "No matches", glyph = "search" } | ||
| 55 | + end | ||
| 56 | + launcher.setResults(query, rows) | ||
| 57 | +end | ||
| 58 | + | ||
| 59 | +function onQuery(query) | ||
| 60 | + lastQuery = query | ||
| 61 | + publish(query) | ||
| 62 | + if apps and noctalia.string.trim(query) ~= "" then | ||
| 63 | + return | ||
| 64 | + end | ||
| 65 | + noctalia.runAsync(SCRIPT .. " list", function(result) | ||
| 66 | + if result.exitCode == 0 then | ||
| 67 | + apps = parse(result.stdout) | ||
| 68 | + publish(lastQuery) | ||
| 69 | + end | ||
| 70 | + end) | ||
| 71 | +end | ||
| 72 | + | ||
| 73 | +function onActivate(id) | ||
| 74 | + -- ids are .desktop paths from our own listing; refuse anything that could break the quoting | ||
| 75 | + if id == "" or id:find("'", 1, true) then | ||
| 76 | + return | ||
| 77 | + end | ||
| 78 | + noctalia.runAsync(SCRIPT .. " run '" .. id .. "'") | ||
| 79 | +end | ||
.config/noctalia/plugins/novpn/plugin.tomladded+17 -0
| @@ -0,0 +1,17 @@ | |||
| 1 | +id = "tahinli/novpn" | ||
| 2 | +name = "Outside VPN" | ||
| 3 | +version = "1.0.0" | ||
| 4 | +plugin_api = 3 | ||
| 5 | +author = "tahinli" | ||
| 6 | +license = "MIT" | ||
| 7 | +dependencies = [] | ||
| 8 | +tags = ["launcher", "vpn"] | ||
| 9 | +icon = "shield-off" | ||
| 10 | +description = "Launch desktop apps outside the Mullvad tunnel (mullvad-exclude)." | ||
| 11 | + | ||
| 12 | +[[launcher_provider]] | ||
| 13 | +id = "novpn" | ||
| 14 | +entry = "novpn.luau" | ||
| 15 | +prefix = "novpn" | ||
| 16 | +glyph = "shield-off" | ||
| 17 | +include_in_global_search = false | ||
.config/noctalia/shell.tomladded+2 -0
| @@ -0,0 +1,2 @@ | |||
| 1 | +[shell.animation] | ||
| 2 | +speed = 1.5 | ||
.config/noctalia/templates.tomladded+3 -0
| @@ -0,0 +1,3 @@ | |||
| 1 | +[theme.templates] | ||
| 2 | +enable_builtin_templates = true | ||
| 3 | +builtin_ids = ["gtk3", "gtk4", "qt", "kcolorscheme", "niri", "wezterm"] | ||
.config/noctalia/widgets.tomladded+4 -0
| @@ -0,0 +1,4 @@ | |||
| 1 | +[widget.clock] | ||
| 2 | +format = "{:%H:%M:%S %a %d.%m}" | ||
| 3 | +vertical_format = "{:%H\n%M\n%S}" | ||
| 4 | +tooltip_format = "{:%A, %d %B %Y}" | ||
.config/scripts/shared/novpn_apps.shadded+63 -0
| @@ -0,0 +1,63 @@ | |||
| 1 | +#!/bin/bash | ||
| 2 | +# Backend for the tahinli/novpn Noctalia plugin: start desktop apps outside the Mullvad tunnel. | ||
| 3 | +# novpn_apps.sh list -> "Name<TAB>Description<TAB>Icon<TAB>/path/to/app.desktop" per app | ||
| 4 | +# novpn_apps.sh run <path> -> launch that app under mullvad-exclude | ||
| 5 | + | ||
| 6 | +DIRS=( | ||
| 7 | + "$HOME/.local/share/applications" | ||
| 8 | + "$HOME/.local/share/flatpak/exports/share/applications" | ||
| 9 | + "/var/lib/flatpak/exports/share/applications" | ||
| 10 | + "/usr/local/share/applications" | ||
| 11 | + "/usr/share/applications" | ||
| 12 | +) | ||
| 13 | + | ||
| 14 | +list_apps() { | ||
| 15 | + declare -A seen | ||
| 16 | + for dir in "${DIRS[@]}"; do | ||
| 17 | + [ -d "$dir" ] || continue | ||
| 18 | + for file in "$dir"/*.desktop; do | ||
| 19 | + [ -f "$file" ] || continue | ||
| 20 | + id=$(basename "$file") | ||
| 21 | + # first directory wins, like XDG lookup | ||
| 22 | + [ -n "${seen[$id]}" ] && continue | ||
| 23 | + seen[$id]=1 | ||
| 24 | + # prints "Name<TAB>GenericName-or-Comment<TAB>Icon" | ||
| 25 | + info=$(awk -F= ' | ||
| 26 | + /^\[/ { main = ($0 == "[Desktop Entry]") } | ||
| 27 | + !main { next } | ||
| 28 | + $1 == "Type" && $2 != "Application" { skip = 1 } | ||
| 29 | + ($1 == "NoDisplay" || $1 == "Hidden") && $2 == "true" { skip = 1 } | ||
| 30 | + $1 == "Name" && name == "" { name = substr($0, 6) } | ||
| 31 | + $1 == "GenericName" && generic == "" { generic = substr($0, 13) } | ||
| 32 | + $1 == "Comment" && comment == "" { comment = substr($0, 9) } | ||
| 33 | + $1 == "Icon" && icon == "" { icon = substr($0, 6) } | ||
| 34 | + END { | ||
| 35 | + if (!skip && name != "") | ||
| 36 | + printf "%s\t%s\t%s", name, (generic != "" ? generic : comment), icon | ||
| 37 | + } | ||
| 38 | + ' "$file") | ||
| 39 | + [ -n "$info" ] && printf '%s\t%s\n' "$info" "$file" | ||
| 40 | + done | ||
| 41 | + done | sort -f | ||
| 42 | +} | ||
| 43 | + | ||
| 44 | +run_app() { | ||
| 45 | + # the .desktop path is the last field, whether {selection} arrived quoted or word-split | ||
| 46 | + file="${*: -1}" | ||
| 47 | + file="${file##*$'\t'}" | ||
| 48 | + [ -f "$file" ] || exit 1 | ||
| 49 | + cmd=$(awk ' | ||
| 50 | + /^\[/ { main = ($0 == "[Desktop Entry]") } | ||
| 51 | + main && /^Exec=/ { print substr($0, 6); exit } | ||
| 52 | + ' "$file") | ||
| 53 | + [ -n "$cmd" ] || exit 1 | ||
| 54 | + # drop desktop-entry field codes (%U, %f, ...) and unescape %% | ||
| 55 | + cmd=$(printf '%s' "$cmd" | sed -E 's/ ?%[fFuUdDnNickvm]//g; s/%%/%/g') | ||
| 56 | + setsid -f mullvad-exclude sh -c "$cmd" >/dev/null 2>&1 | ||
| 57 | +} | ||
| 58 | + | ||
| 59 | +case "$1" in | ||
| 60 | + list) list_apps ;; | ||
| 61 | + run) shift; run_app "$@" ;; | ||
| 62 | + *) echo "Usage: $0 {list|run <line>}" >&2; exit 1 ;; | ||
| 63 | +esac | ||
.gitignoremodified+3 -0
| @@ -6,3 +6,6 @@ | |||
| 6 | .config/gtk-3.0/gtk.css | 6 | .config/gtk-3.0/gtk.css |
| 7 | .config/gtk-4.0/gtk.css | 7 | .config/gtk-4.0/gtk.css |
| 8 | .config/gtk-4.0/gtk-dark.css | 8 | .config/gtk-4.0/gtk-dark.css |
| 9 | + | ||
| 10 | +# Noctalia generated files (wallpaper colours) | ||
| 11 | +.config/niri/noctalia.kdl | ||
.local/state/noctalia/settings.tomladded+209 -0
| @@ -0,0 +1,209 @@ | |||
| 1 | +config_version = 14 | ||
| 2 | + | ||
| 3 | +[audio] | ||
| 4 | +enable_overdrive = true | ||
| 5 | +enable_sounds = false | ||
| 6 | + | ||
| 7 | +[bar.default] | ||
| 8 | +background_opacity = 0.74999998323619366 | ||
| 9 | +compositor_blur = false | ||
| 10 | +contact_shadow = true | ||
| 11 | +start = [ "workspaces", "gap", "media", "audio_visualizer" ] | ||
| 12 | + | ||
| 13 | +[location] | ||
| 14 | +address = "Kayseri" | ||
| 15 | + | ||
| 16 | +[lockscreen] | ||
| 17 | +transition_duration = 200 | ||
| 18 | + | ||
| 19 | +[lockscreen_widgets] | ||
| 20 | +enabled = true | ||
| 21 | +schema_version = 2 | ||
| 22 | +widget_order = [ | ||
| 23 | + "lockscreen-login-box@DP-1", | ||
| 24 | + "lockscreen-login-box@HDMI-A-1", | ||
| 25 | + "lockscreen-widget-0000000000000004", | ||
| 26 | + "lockscreen-widget-0000000000000005" | ||
| 27 | +] | ||
| 28 | + | ||
| 29 | + [lockscreen_widgets.grid] | ||
| 30 | + cell_size = 16 | ||
| 31 | + major_interval = 4 | ||
| 32 | + visible = false | ||
| 33 | + | ||
| 34 | + [lockscreen_widgets.widget."lockscreen-login-box@DP-1"] | ||
| 35 | + box_height = 196.0 | ||
| 36 | + box_width = 810.0 | ||
| 37 | + cx = 1280.0 | ||
| 38 | + cy = 1258.0 | ||
| 39 | + output = "DP-1" | ||
| 40 | + placement_height = 1440.0 | ||
| 41 | + placement_width = 2560.0 | ||
| 42 | + rotation = 0.0 | ||
| 43 | + type = "login_box" | ||
| 44 | + | ||
| 45 | + [lockscreen_widgets.widget."lockscreen-login-box@DP-1".settings] | ||
| 46 | + background_color = "surface_variant" | ||
| 47 | + background_opacity = 0.88 | ||
| 48 | + background_radius = 12.0 | ||
| 49 | + center_password_text = false | ||
| 50 | + input_opacity = 1.0 | ||
| 51 | + input_radius = 6.0 | ||
| 52 | + layout = "regular" | ||
| 53 | + show_caps_lock = true | ||
| 54 | + show_keyboard_layout = true | ||
| 55 | + show_login_button = true | ||
| 56 | + show_media = true | ||
| 57 | + show_session_buttons = true | ||
| 58 | + show_unlock_hint = true | ||
| 59 | + show_weather = true | ||
| 60 | + | ||
| 61 | + [lockscreen_widgets.widget."lockscreen-login-box@HDMI-A-1"] | ||
| 62 | + box_height = 196.0 | ||
| 63 | + box_width = 810.0 | ||
| 64 | + cx = 960.0 | ||
| 65 | + cy = 898.0 | ||
| 66 | + output = "HDMI-A-1" | ||
| 67 | + placement_height = 1080.0 | ||
| 68 | + placement_width = 1920.0 | ||
| 69 | + rotation = 0.0 | ||
| 70 | + type = "login_box" | ||
| 71 | + | ||
| 72 | + [lockscreen_widgets.widget."lockscreen-login-box@HDMI-A-1".settings] | ||
| 73 | + background_color = "surface_variant" | ||
| 74 | + background_opacity = 0.88 | ||
| 75 | + background_radius = 12.0 | ||
| 76 | + center_password_text = false | ||
| 77 | + input_opacity = 1.0 | ||
| 78 | + input_radius = 6.0 | ||
| 79 | + layout = "regular" | ||
| 80 | + show_caps_lock = true | ||
| 81 | + show_keyboard_layout = true | ||
| 82 | + show_login_button = true | ||
| 83 | + show_media = true | ||
| 84 | + show_session_buttons = true | ||
| 85 | + show_unlock_hint = true | ||
| 86 | + show_weather = true | ||
| 87 | + | ||
| 88 | + [lockscreen_widgets.widget.lockscreen-widget-0000000000000004] | ||
| 89 | + box_height = 224.0 | ||
| 90 | + box_width = 496.0 | ||
| 91 | + cx = 1280.0 | ||
| 92 | + cy = 720.0 | ||
| 93 | + output = "DP-1" | ||
| 94 | + placement_height = 1440.0 | ||
| 95 | + placement_width = 2560.0 | ||
| 96 | + rotation = 0.0 | ||
| 97 | + type = "clock" | ||
| 98 | + | ||
| 99 | + [lockscreen_widgets.widget.lockscreen-widget-0000000000000004.settings] | ||
| 100 | + background = false | ||
| 101 | + clock_style = "digital" | ||
| 102 | + color = "on_surface" | ||
| 103 | + format = " %H:%M:%S" | ||
| 104 | + shadow = true | ||
| 105 | + | ||
| 106 | + [lockscreen_widgets.widget.lockscreen-widget-0000000000000005] | ||
| 107 | + box_height = 73.0 | ||
| 108 | + box_width = 83.0 | ||
| 109 | + cx = 1280.0 | ||
| 110 | + cy = 633.5 | ||
| 111 | + output = "DP-1" | ||
| 112 | + placement_height = 1440.0 | ||
| 113 | + placement_width = 2560.0 | ||
| 114 | + rotation = 0.0 | ||
| 115 | + type = "clock" | ||
| 116 | + | ||
| 117 | + [lockscreen_widgets.widget.lockscreen-widget-0000000000000005.settings] | ||
| 118 | + background = false | ||
| 119 | + format = "%A\\n%d.%m.%y" | ||
| 120 | + shadow = true | ||
| 121 | + | ||
| 122 | +[notification] | ||
| 123 | +background_opacity = 0.50999998860061169 | ||
| 124 | + | ||
| 125 | +[osd] | ||
| 126 | +background_opacity = 0.84999998100101948 | ||
| 127 | +hide_delay_ms = 2000 | ||
| 128 | +orientation = "vertical" | ||
| 129 | +position_vertical = "bottom_right" | ||
| 130 | +scale = 1.0000000074505806 | ||
| 131 | + | ||
| 132 | +[plugins] | ||
| 133 | +enabled = [ "tahinli/novpn" ] | ||
| 134 | + | ||
| 135 | + [[plugins.source]] | ||
| 136 | + kind = "git" | ||
| 137 | + location = "https://github.com/noctalia-dev/official-plugins" | ||
| 138 | + name = "official" | ||
| 139 | + | ||
| 140 | + [[plugins.source]] | ||
| 141 | + kind = "git" | ||
| 142 | + location = "https://github.com/noctalia-dev/community-plugins" | ||
| 143 | + name = "community" | ||
| 144 | + | ||
| 145 | + [[plugins.source]] | ||
| 146 | + kind = "path" | ||
| 147 | + location = "/home/tahinli/.config/noctalia/plugins" | ||
| 148 | + name = "local" | ||
| 149 | + | ||
| 150 | +[shell] | ||
| 151 | +clipboard_auto_paste = "off" | ||
| 152 | +clipboard_history_max_entries = 2000 | ||
| 153 | +external_ip_enabled = true | ||
| 154 | +niri_overview_type_to_launch_enabled = true | ||
| 155 | +polkit_agent = true | ||
| 156 | +time_format = "{:%H:%M:%S}" | ||
| 157 | + | ||
| 158 | + [shell.animation] | ||
| 159 | + speed = 2.0000000298023224 | ||
| 160 | + | ||
| 161 | + [shell.greeter_sync] | ||
| 162 | + auto_sync = true | ||
| 163 | + | ||
| 164 | + [shell.panel] | ||
| 165 | + open_near_click_clipboard = true | ||
| 166 | + transparency_mode = "glass" | ||
| 167 | + | ||
| 168 | + [shell.screenshot] | ||
| 169 | + directory = "/home/tahinli/Pictures/Screenshots" | ||
| 170 | + | ||
| 171 | +[system.monitor] | ||
| 172 | +cpu_poll_seconds = 1 | ||
| 173 | +disk_poll_seconds = 1 | ||
| 174 | +gpu_poll_seconds = 1 | ||
| 175 | +memory_poll_seconds = 1 | ||
| 176 | +network_poll_seconds = 1 | ||
| 177 | + | ||
| 178 | +[theme] | ||
| 179 | +builtin = "Noctalia" | ||
| 180 | +community_palette = "Oxocarbon" | ||
| 181 | +mode = "dark" | ||
| 182 | +source = "wallpaper" | ||
| 183 | +wallpaper_scheme = "m3-content" | ||
| 184 | + | ||
| 185 | +[wallpaper] | ||
| 186 | +directory = "/home/tahinli/Pictures/Wallpapers" | ||
| 187 | +transition_duration = 500 | ||
| 188 | +transition_on_startup = true | ||
| 189 | + | ||
| 190 | + [wallpaper.default] | ||
| 191 | + path = "/home/tahinli/Pictures/Wallpapers/matthew-stephenson-TZUM4rwER2k-unsplash.jpg" | ||
| 192 | + | ||
| 193 | + [wallpaper.last] | ||
| 194 | + path = "/home/tahinli/Pictures/Wallpapers/matthew-stephenson-TZUM4rwER2k-unsplash.jpg" | ||
| 195 | + | ||
| 196 | + [wallpaper.monitors.DP-1] | ||
| 197 | + path = "/home/tahinli/Pictures/Wallpapers/matthew-stephenson-TZUM4rwER2k-unsplash.jpg" | ||
| 198 | + | ||
| 199 | + [wallpaper.monitors.HDMI-A-1] | ||
| 200 | + path = "/home/tahinli/Pictures/Wallpapers/matthew-stephenson-TZUM4rwER2k-unsplash.jpg" | ||
| 201 | + | ||
| 202 | +[widget.audio_visualizer] | ||
| 203 | +bands = 32 | ||
| 204 | +mirrored = false | ||
| 205 | +width = 64 | ||
| 206 | + | ||
| 207 | +[widget.media] | ||
| 208 | +anchor = true | ||
| 209 | +show_progress = true | ||
| \ No newline at end of file | \ No newline at end of file | ||
.wezterm.luamodified+4 -0
| @@ -17,4 +17,8 @@ config.cursor_blink_ease_out = "Constant" | |||
| 17 | 17 | ||
| 18 | config.warn_about_missing_glyphs = false | 18 | config.warn_about_missing_glyphs = false |
| 19 | 19 | ||
| 20 | +-- colors from noctalia's wezterm template | ||
| 21 | +config.color_scheme_dirs = { wezterm.home_dir .. "/.config/wezterm/colors" } | ||
| 22 | +config.color_scheme = "Noctalia" | ||
| 23 | + | ||
| 20 | return config | 24 | return config |