diff --git a/.config/hypr/apps.conf b/.config/hypr/apps.conf index 808b763..bb37c1d 100644 --- a/.config/hypr/apps.conf +++ b/.config/hypr/apps.conf @@ -16,9 +16,9 @@ windowrule = opacity 1.0 0.97, match:tag chromium-based-browser windowrule = opacity 1.0 0.97, match:tag firefox-based-browser windowrule { - name = geforce - match:class = GeForceNOW - idle_inhibit = fullscreen + name = geforce + match:class = GeForceNOW + idle_inhibit = fullscreen } # Remove 1px border around hyprshot screenshots @@ -67,6 +67,15 @@ windowrule { match:class = ^(jetbrains-.*)$ } +# Keep enpass focused +windowrule { + name = enpass-assistant + match:title = ^(Enpass Assistant)$ + match:class = ^(Enpass)$ + stay_focused = on + center = on +} + # Float LocalSend and fzf file picker windowrule = float on, match:class (Share|localsend) windowrule = center on, match:class (Share|localsend) @@ -106,14 +115,14 @@ windowrule = float on, match:tag floating-window windowrule = center on, match:tag floating-window windowrule = size 875 600, match:tag floating-window -windowrule = tag +floating-window, match:class (org.omarchy.bluetui|org.omarchy.impala|org.omarchy.wiremix|org.omarchy.btop|org.omarchy.terminal|org.omarchy.bash|org.gnome.NautilusPreviewer|org.gnome.Evince|com.gabm.satty|Omarchy|About|TUI.float|imv|mpv) +windowrule = tag +floating-window, match:class (org.station.bluetui|org.station.impala|org.station.wiremix|org.station.btop|org.station.terminal|org.station.bash|org.gnome.NautilusPreviewer|org.gnome.Evince|com.gabm.satty|Station|About|TUI.float|imv|mpv) windowrule = tag +floating-window, match:class (xdg-desktop-portal-gtk|sublime_text|DesktopEditors|org.gnome.Nautilus), match:title ^(Open.*Files?|Open [F|f]older.*|Save.*Files?|Save.*As|Save|All Files|.*wants to [open|save].*|[C|c]hoose.*) windowrule = float on, match:class org.gnome.Calculator # Fullscreen screensaver -windowrule = fullscreen on, match:class org.omarchy.screensaver -windowrule = float on, match:class org.omarchy.screensaver -windowrule = animation slide, match:class org.omarchy.screensaver +windowrule = fullscreen on, match:class org.station.screensaver +windowrule = float on, match:class org.station.screensaver +windowrule = animation slide, match:class org.station.screensaver # No transparency on media windows windowrule = tag -default-opacity, match:class ^(zoom|vlc|mpv|org.kde.kdenlive|com.obsproject.Studio|com.github.PintaProject.Pinta|imv|org.gnome.NautilusPreviewer)$ diff --git a/.config/hypr/bindings.conf b/.config/hypr/bindings.conf index ecc912c..2c2593a 100644 --- a/.config/hypr/bindings.conf +++ b/.config/hypr/bindings.conf @@ -176,53 +176,49 @@ bindd = SUPER, SPACE, Launch apps, exec, station-launch-walker bindd = SUPER CTRL, E, Emoji picker, exec, station-launch-walker -m symbols bindd = SUPER CTRL, C, Capture menu, exec, station-menu capture bindd = SUPER CTRL, O, Toggle menu, exec, station-menu toggle -bindd = SUPER ALT, SPACE, Omarchy menu, exec, station-menu +bindd = SUPER ALT, SPACE, Station menu, exec, station-menu bindd = SUPER, ESCAPE, System menu, exec, station-menu system bindld = , XF86PowerOff, Power menu, exec, station-menu system bindd = SUPER, K, Show key bindings, exec, station-menu-keybindings bindd = , XF86Calculator, Calculator, exec, gnome-calculator # Aesthetics -# bindd = SUPER SHIFT, SPACE, Toggle top bar, exec, omarchy-toggle-waybar -# bindd = SUPER CTRL, SPACE, Theme background menu, exec, omarchy-menu background -# bindd = SUPER SHIFT CTRL, SPACE, Theme menu, exec, omarchy-menu theme +bindd = SUPER SHIFT, SPACE, Toggle top bar, exec, station-toggle-waybar +bindd = SUPER CTRL, SPACE, Theme background menu, exec, station-menu background +# bindd = SUPER SHIFT CTRL, SPACE, Theme menu, exec, station-menu theme bindd = SUPER, BACKSPACE, Toggle window transparency, exec, hyprctl dispatch setprop "address:$(hyprctl activewindow -j | jq -r '.address')" opaque toggle -# bindd = SUPER SHIFT, BACKSPACE, Toggle window gaps, exec, omarchy-hyprland-window-gaps-toggle -# bindd = SUPER CTRL, Backspace, Toggle single-window square aspect, exec, omarchy-hyprland-window-single-square-aspect-toggle +bindd = SUPER SHIFT, BACKSPACE, Toggle window gaps, exec, station-hyprland-window-gaps-toggle +bindd = SUPER CTRL, Backspace, Toggle single-window square aspect, exec, station-hyprland-window-single-square-aspect-toggle # Notifications -# bindd = SUPER, COMMA, Dismiss last notification, exec, makoctl dismiss -# bindd = SUPER SHIFT, COMMA, Dismiss all notifications, exec, makoctl dismiss --all -# bindd = SUPER CTRL, COMMA, Toggle silencing notifications, exec, omarchy-toggle-notification-silencing -# bindd = SUPER ALT, COMMA, Invoke last notification, exec, makoctl invoke -# bindd = SUPER SHIFT ALT, COMMA, Restore last notification, exec, makoctl restore +bindd = SUPER, COMMA, Dismiss last notification, exec, makoctl dismiss +bindd = SUPER SHIFT, COMMA, Dismiss all notifications, exec, makoctl dismiss --all +bindd = SUPER CTRL, COMMA, Toggle silencing notifications, exec, station-toggle-notification-silencing +bindd = SUPER ALT, COMMA, Invoke last notification, exec, makoctl invoke +bindd = SUPER SHIFT ALT, COMMA, Restore last notification, exec, makoctl restore # Toggles -# bindd = SUPER CTRL, I, Toggle locking on idle, exec, omarchy-toggle-idle -# bindd = SUPER CTRL, N, Toggle nightlight, exec, omarchy-toggle-nightlight - -# Control Apple Display brightness -# bindd = CTRL, F1, Apple Display brightness down, exec, omarchy-brightness-display-apple -5000 -# bindd = CTRL, F2, Apple Display brightness up, exec, omarchy-brightness-display-apple +5000 -# bindd = SHIFT CTRL, F2, Apple Display full brightness, exec, omarchy-brightness-display-apple +60000 +bindd = SUPER CTRL, I, Toggle locking on idle, exec, station-toggle-idle +bindd = SUPER CTRL, N, Toggle nightlight, exec, station-toggle-nightlight # Captures -# bindd = , PRINT, Screenshot, exec, omarchy-cmd-screenshot -# bindd = ALT, PRINT, Screenrecording, exec, omarchy-menu screenrecord -# bindd = SUPER, PRINT, Color picker, exec, pkill hyprpicker || hyprpicker -a +bindd = , PRINT, Screenshot, exec, station-cmd-screenshot +bindd = ALT, PRINT, Screenrecording, exec, station-menu screenrecord +bindd = SUPER, PRINT, Color picker, exec, pkill hyprpicker || hyprpicker -a # File sharing -# bindd = SUPER CTRL, S, Share, exec, omarchy-menu share +bindd = SUPER CTRL, S, Share, exec, station-menu share # Waybar-less information bindd = SUPER CTRL ALT, T, Show time, exec, notify-send " $(date +"%A %H:%M — %d %B W%V %Y")" -bindd = SUPER CTRL ALT, B, Show battery remaining, exec, notify-send "󰁹 Battery is at $(omarchy-battery-remaining)%" +bindd = SUPER CTRL ALT, B, Show battery remaining, exec, notify-send "󰁹 Battery is at $(station-battery-remaining)%" +bindd = SUPER CTRL ALT, W, Show active window name and class, exec, notify-send "$(hyprctl activewindow -j | jq -r '"Window: \(.title)\nClass: \(.class)"')" # Control panels -# bindd = SUPER CTRL, A, Audio controls, exec, omarchy-launch-audio -# bindd = SUPER CTRL, B, Bluetooth controls, exec, omarchy-launch-bluetooth -# bindd = SUPER CTRL, W, Wifi controls, exec, omarchy-launch-wifi -# bindd = SUPER CTRL, T, Activity, exec, omarchy-launch-tui btop +bindd = SUPER CTRL, A, Audio controls, exec, station-launch-audio +bindd = SUPER CTRL, B, Bluetooth controls, exec, station-launch-bluetooth +bindd = SUPER CTRL, W, Wifi controls, exec, station-launch-wifi +bindd = SUPER CTRL, T, Activity, exec, station-launch-tui btop # Dictation # bindd = SUPER CTRL, X, Toggle dictation, exec, voxtype record toggle @@ -232,7 +228,7 @@ bindd = SUPER CTRL, Z, Zoom in, exec, hyprctl keyword cursor:zoom_factor $(hyprc bindd = SUPER CTRL ALT, Z, Reset zoom, exec, hyprctl keyword cursor:zoom_factor 1 # Lock system -# bindd = SUPER CTRL, L, Lock system, exec, omarchy-lock-screen +bindd = SUPER CTRL, L, Lock system, exec, station-lock-screen # ========================== # Applications @@ -240,33 +236,28 @@ bindd = SUPER CTRL ALT, Z, Reset zoom, exec, hyprctl keyword cursor:zoom_factor bindd = SUPER, RETURN, Terminal, exec, uwsm-app -- xdg-terminal-exec --dir="$(station-cmd-terminal-cwd)" bindd = SUPER ALT, RETURN, Tmux, exec, uwsm-app -- xdg-terminal-exec --dir="$(station-cmd-terminal-cwd)" tmux new bindd = SUPER SHIFT, F, File manager, exec, uwsm-app -- nautilus --new-window -# bindd = SUPER ALT SHIFT, F, File manager (cwd), exec, uwsm-app -- nautilus --new-window "$(omarchy-cmd-terminal-cwd)" -debug:disable_logs = false +bindd = SUPER ALT SHIFT, F, File manager (cwd), exec, uwsm-app -- nautilus --new-window "$(station-cmd-terminal-cwd)" bindd = SUPER SHIFT, B, Browser, exec, /home/chris/.local/bin/station-launch-browser bindd = SUPER SHIFT ALT, B, Browser (private), exec, station-launch-browser --private -# bindd = SUPER SHIFT, M, Music, exec, omarchy-launch-or-focus spotify -# bindd = SUPER SHIFT, N, Editor, exec, omarchy-launch-editor -# bindd = SUPER SHIFT, D, Docker, exec, omarchy-launch-tui lazydocker -# bindd = SUPER SHIFT, G, Signal, exec, omarchy-launch-or-focus ^signal$ "uwsm-app -- signal-desktop" -# bindd = SUPER SHIFT, O, Obsidian, exec, omarchy-launch-or-focus ^obsidian$ "uwsm-app -- obsidian -disable-gpu --enable-wayland-ime" +bindd = SUPER SHIFT, M, Music, exec, station-launch-or-focus spotify +bindd = SUPER SHIFT, N, Editor, exec, station-launch-editor +# bindd = SUPER SHIFT, D, Docker, exec, station-launch-tui lazydocker +bindd = SUPER SHIFT, G, Signal, exec, station-launch-or-focus ^signal$ "uwsm-app -- signal-desktop" +bindd = SUPER SHIFT, O, Obsidian, exec, station-launch-or-focus ^obsidian$ "uwsm-app -- obsidian -disable-gpu --enable-wayland-ime" # bindd = SUPER SHIFT, W, Typora, exec, uwsm-app -- typora --enable-wayland-ime bindd = SUPER SHIFT, SLASH, Passwords, exec, uwsm-app -- Enpass +bindd = SUPER SHIFT, E, Email, exec, station-launch-or-focus mailspring # If your web app url contains #, type it as ## to prevent hyprland treating it as a comment -# bindd = SUPER SHIFT, A, ChatGPT, exec, omarchy-launch-webapp "https://chatgpt.com" -# bindd = SUPER SHIFT ALT, A, Grok, exec, omarchy-launch-webapp "https://grok.com" -# bindd = SUPER SHIFT, C, Calendar, exec, omarchy-launch-webapp "https://app.hey.com/calendar/weeks/" -# bindd = SUPER SHIFT, E, Email, exec, omarchy-launch-webapp "https://app.hey.com" -# bindd = SUPER SHIFT, Y, YouTube, exec, omarchy-launch-webapp "https://youtube.com/" -# bindd = SUPER SHIFT ALT, G, WhatsApp, exec, omarchy-launch-or-focus-webapp WhatsApp "https://web.whatsapp.com/" -# bindd = SUPER SHIFT CTRL, G, Google Messages, exec, omarchy-launch-or-focus-webapp "Google Messages" "https://messages.google.com/web/conversations" -# bindd = SUPER SHIFT, P, Google Photos, exec, omarchy-launch-or-focus-webapp "Google Photos" "https://photos.google.com/" -# bindd = SUPER SHIFT, X, X, exec, omarchy-launch-webapp "https://x.com/" -# bindd = SUPER SHIFT ALT, X, X Post, exec, omarchy-launch-webapp "https://x.com/compose/post" +bindd = SUPER SHIFT, A, ChatGPT, exec, station-launch-webapp "https://gemini.google.com/app" +bindd = SUPER SHIFT, C, Calendar, exec, station-launch-webapp "https://tower.scarif.space/apps/calendar" +bindd = SUPER SHIFT, Y, YouTube, exec, station-launch-or-focus-webapp "YouTube" "https://youtube.com/" +bindd = SUPER SHIFT ALT, G, WhatsApp, exec, station-launch-or-focus-webapp WhatsApp "https://web.whatsapp.com/" +bindd = SUPER SHIFT CTRL, G, Google Maps, exec, station-launch-or-focus-webapp "Google Maps" "https://maps.google.com" +# bindd = SUPER SHIFT, P, Google Photos, exec, station-launch-or-focus-webapp "Google Photos" "https://photos.google.com/" +# bindd = SUPER SHIFT, X, X, exec, station-launch-webapp "https://x.com/" +# bindd = SUPER SHIFT ALT, X, X Post, exec, station-launch-webapp "https://x.com/compose/post" # Add extra bindings -# bind = SUPER SHIFT, R, exec, alacritty -e ssh your-server +bind = SUPER SHIFT, R, exec, ghostty -e ssh scarif -# Overwrite existing bindings, like putting Omarchy Menu on Super + Space -# unbind = SUPER, SPACE -# bindd = SUPER, SPACE, Omarchy menu, exec, omarchy-menu diff --git a/.local/bin/station-battery-remaining b/.local/bin/station-battery-remaining new file mode 100755 index 0000000..26ea718 --- /dev/null +++ b/.local/bin/station-battery-remaining @@ -0,0 +1,9 @@ +#!/bin/bash + +# Returns the battery percentage remaining as an integer. +# Used by the battery monitor and the Ctrl + Shift + Super + B hotkey. + +upower -i $(upower -e | grep BAT) | awk '/percentage/ { + print int($2) + exit +}' diff --git a/.local/bin/station-launch-webapp b/.local/bin/station-launch-webapp index 607ef6c..e324e3f 100755 --- a/.local/bin/station-launch-webapp +++ b/.local/bin/station-launch-webapp @@ -9,4 +9,6 @@ google-chrome* | brave-browser* | microsoft-edge* | opera* | vivaldi* | helium*) *) browser="chromium.desktop" ;; esac +echo $browser + exec setsid uwsm-app -- $(sed -n 's/^Exec=\([^ ]*\).*/\1/p' {~/.local,~/.nix-profile,/usr}/share/applications/$browser 2>/dev/null | head -1) --app="$1" "${@:2}" diff --git a/.local/bin/station-lock-screen b/.local/bin/station-lock-screen new file mode 100755 index 0000000..ae3d254 --- /dev/null +++ b/.local/bin/station-lock-screen @@ -0,0 +1,12 @@ +#!/bin/bash + +# Locks the system using hyprlock, but not before ensuring the screensaver stopped. + +# Lock the screen +pidof hyprlock || hyprlock & + +# Set keyboard layout to default (first layout) +hyprctl switchxkblayout all 0 > /dev/null 2>&1 + +# Avoid running screensaver when locked +pkill -f org.station.screensaver diff --git a/.local/bin/station-toggle-notification-silencing b/.local/bin/station-toggle-notification-silencing new file mode 100755 index 0000000..9350d75 --- /dev/null +++ b/.local/bin/station-toggle-notification-silencing @@ -0,0 +1,11 @@ +#!/bin/bash + +makoctl mode -t do-not-disturb + +if makoctl mode | grep -q 'do-not-disturb'; then + notify-send "󰂛 Silenced notifications" +else + notify-send "󰂚 Enabled notifications" +fi + +pkill -RTMIN+10 waybar