From b911a6f8ba51ac36b7bef9cd07b96207a2c59a18 Mon Sep 17 00:00:00 2001 From: Pavel Kadera <149444217+r3quie@users.noreply.github.com> Date: Thu, 21 May 2026 06:48:20 +0200 Subject: [PATCH] Only bind F9 to Voxtype if installed (#5882) (#5897) --- bin/omarchy-voxtype-install | 1 + bin/omarchy-voxtype-remove | 1 + default/hypr/bindings/utilities.lua | 4 ---- default/hypr/toggles/voxtype.lua | 3 +++ migrations/1779297337.sh | 5 +++++ 5 files changed, 10 insertions(+), 4 deletions(-) create mode 100644 default/hypr/toggles/voxtype.lua create mode 100644 migrations/1779297337.sh diff --git a/bin/omarchy-voxtype-install b/bin/omarchy-voxtype-install index 32a1153e..c893f1a1 100755 --- a/bin/omarchy-voxtype-install +++ b/bin/omarchy-voxtype-install @@ -20,6 +20,7 @@ if gum confirm "Install Voxtype + AI model (~150MB) to enable dictation?"; then fi voxtype setup systemd + omarchy-hyprland-toggle voxtype on omarchy-restart-waybar notify-send " Voxtype Dictation Ready" "Hold F9 to dictate (or toggle with Super + Ctrl + X)." -t 10000 fi diff --git a/bin/omarchy-voxtype-remove b/bin/omarchy-voxtype-remove index 3ca45703..3cab07b3 100755 --- a/bin/omarchy-voxtype-remove +++ b/bin/omarchy-voxtype-remove @@ -18,6 +18,7 @@ if omarchy-cmd-present voxtype; then omarchy-pkg-drop voxtype-bin rm -rf ~/.config/voxtype rm -rf ~/.local/share/voxtype + omarchy-hyprland-toggle voxtype off else echo "Voxtype was not installed." fi diff --git a/default/hypr/bindings/utilities.lua b/default/hypr/bindings/utilities.lua index 472dd06b..e167256d 100644 --- a/default/hypr/bindings/utilities.lua +++ b/default/hypr/bindings/utilities.lua @@ -57,10 +57,6 @@ o.bind("SUPER + CTRL + B", "Bluetooth controls", { omarchy = "bluetooth" }) o.bind("SUPER + CTRL + W", "Wifi controls", { omarchy = "wifi" }) o.bind("SUPER + CTRL + T", "Activity", { tui = "btop" }) -o.bind("SUPER + CTRL + X", "Toggle dictation", "voxtype record toggle") -o.bind("F9", "Start dictation (push-to-talk)", "voxtype record start") -o.bind("F9", "Stop dictation (push-to-talk)", "voxtype record stop", { release = true }) - o.bind("SUPER + CTRL + Z", "Zoom in", function() local zoom = hl.get_config("cursor.zoom_factor") or 1 hl.config({ cursor = { zoom_factor = zoom + 1 } }) diff --git a/default/hypr/toggles/voxtype.lua b/default/hypr/toggles/voxtype.lua new file mode 100644 index 00000000..aa1b81b4 --- /dev/null +++ b/default/hypr/toggles/voxtype.lua @@ -0,0 +1,3 @@ +o.bind("SUPER + CTRL + X", "Toggle dictation", "voxtype record toggle") +o.bind("F9", "Start dictation (push-to-talk)", "voxtype record start") +o.bind("F9", "Stop dictation (push-to-talk)", "voxtype record stop", { release = true }) diff --git a/migrations/1779297337.sh b/migrations/1779297337.sh new file mode 100644 index 00000000..1c48eb6f --- /dev/null +++ b/migrations/1779297337.sh @@ -0,0 +1,5 @@ +echo "Enable Voxtype keybindings toggle for existing installs" + +if omarchy-cmd-present voxtype; then + omarchy-hyprland-toggle voxtype on +fi