From e99afc98f82a7b606d5ace443accd3ee0b6571b0 Mon Sep 17 00:00:00 2001 From: Michael D Lambert Date: Fri, 20 Feb 2026 12:29:45 -0500 Subject: [PATCH 1/3] Simplified battery percentage retrieval command (#2922) * Simplified battery percentage retrieval command Simplified the battery percentage extraction command. * Used int instead of adding 0, put exit back in Changed to use int. Put exit back in to only return first battery in case of systems with multiple batteries. --- bin/omarchy-battery-remaining | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/bin/omarchy-battery-remaining b/bin/omarchy-battery-remaining index a6083352..26ea718f 100755 --- a/bin/omarchy-battery-remaining +++ b/bin/omarchy-battery-remaining @@ -3,10 +3,7 @@ # 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 -F: '/percentage/ { - gsub(/[%[:space:]]/, "", $2); - val=$2; - printf("%d\n", (val+0.5)) +upower -i $(upower -e | grep BAT) | awk '/percentage/ { + print int($2) exit - }' +}' From db3ba3501adfc0156aad87d1e6acb2b8e30fba2c Mon Sep 17 00:00:00 2001 From: Ryan Latimer Date: Fri, 20 Feb 2026 13:37:55 -0500 Subject: [PATCH 2/3] Support single-key keyboard backlight cycling (#4672) * Support single-key keyboard backlight cycling (like Asus F4) and add keyboard specific OSD icon * We don't need an alias --------- Co-authored-by: Ryan Latimer Co-authored-by: David Heinemeier Hansson --- bin/omarchy-brightness-keyboard | 8 +++++--- bin/omarchy-swayosd-kbd-brightness | 15 +++++++++++++++ default/hypr/bindings/media.conf | 1 + 3 files changed, 21 insertions(+), 3 deletions(-) create mode 100755 bin/omarchy-swayosd-kbd-brightness diff --git a/bin/omarchy-brightness-keyboard b/bin/omarchy-brightness-keyboard index ea3a67b2..a05922d2 100755 --- a/bin/omarchy-brightness-keyboard +++ b/bin/omarchy-brightness-keyboard @@ -1,7 +1,7 @@ #!/bin/bash # Adjust keyboard backlight brightness using available steps. -# Usage: omarchy-brightness-keyboard +# Usage: omarchy-brightness-keyboard direction="${1:-up}" @@ -24,7 +24,9 @@ max_brightness="$(brightnessctl -d "$device" max)" current_brightness="$(brightnessctl -d "$device" get)" # Calculate step as one unit (keyboards typically have discrete levels like 0-3). -if [[ "$direction" == "up" ]]; then +if [[ "$direction" == "cycle" ]]; then + new_brightness=$(( (current_brightness + 1) % (max_brightness + 1) )) +elif [[ "$direction" == "up" ]]; then new_brightness=$((current_brightness + 1)) [[ $new_brightness -gt $max_brightness ]] && new_brightness=$max_brightness else @@ -37,4 +39,4 @@ brightnessctl -d "$device" set "$new_brightness" >/dev/null # Use SwayOSD to display the new brightness setting. percent=$((new_brightness * 100 / max_brightness)) -omarchy-swayosd-brightness "$percent" +omarchy-swayosd-kbd-brightness "$percent" diff --git a/bin/omarchy-swayosd-kbd-brightness b/bin/omarchy-swayosd-kbd-brightness new file mode 100755 index 00000000..7102b561 --- /dev/null +++ b/bin/omarchy-swayosd-kbd-brightness @@ -0,0 +1,15 @@ +#!/bin/bash + +# Display keyboard brightness level using SwayOSD on the current monitor. +# Usage: omarchy-swayosd-kbd-brightness + +percent="$1" + +progress="$(awk -v p="$percent" 'BEGIN{printf "%.2f", p/100}')" +[[ "$progress" == "0.00" ]] && progress="0.01" + +swayosd-client \ + --monitor "$(hyprctl monitors -j | jq -r '.[]|select(.focused==true).name')" \ + --custom-icon keyboard-brightness \ + --custom-progress "$progress" \ + --custom-progress-text "${percent}%" diff --git a/default/hypr/bindings/media.conf b/default/hypr/bindings/media.conf index 38334119..9506ff41 100644 --- a/default/hypr/bindings/media.conf +++ b/default/hypr/bindings/media.conf @@ -10,6 +10,7 @@ bindeld = ,XF86MonBrightnessUp, Brightness up, exec, omarchy-brightness-display bindeld = ,XF86MonBrightnessDown, Brightness down, exec, omarchy-brightness-display 5%- bindeld = ,XF86KbdBrightnessUp, Keyboard brightness up, exec, omarchy-brightness-keyboard up bindeld = ,XF86KbdBrightnessDown, Keyboard brightness down, exec, omarchy-brightness-keyboard down +bindld = ,XF86KbdLightOnOff, Keyboard backlight cycle, exec, omarchy-brightness-keyboard cycle # Precise 1% multimedia adjustments with Alt modifier bindeld = ALT, XF86AudioRaiseVolume, Volume up precise, exec, $osdclient --output-volume +1 From 5ef4426577cc5a6a57d38a2a8ddcf5e6927e9bc6 Mon Sep 17 00:00:00 2001 From: guidovicino Date: Fri, 20 Feb 2026 19:39:34 +0100 Subject: [PATCH 3/3] Add Tmux to the config refresh menu (#4671) --- bin/omarchy-menu | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/omarchy-menu b/bin/omarchy-menu index c2f19e47..d5239803 100755 --- a/bin/omarchy-menu +++ b/bin/omarchy-menu @@ -527,13 +527,14 @@ show_update_process_menu() { } show_update_config_menu() { - case $(menu "Use default config" " Hyprland\n Hypridle\n Hyprlock\n Hyprsunset\n󱣴 Plymouth\n Swayosd\n󰌧 Walker\n󰍜 Waybar") in + case $(menu "Use default config" " Hyprland\n Hypridle\n Hyprlock\n Hyprsunset\n󱣴 Plymouth\n Swayosd\n Tmux\n󰌧 Walker\n󰍜 Waybar") in *Hyprland*) present_terminal omarchy-refresh-hyprland ;; *Hypridle*) present_terminal omarchy-refresh-hypridle ;; *Hyprlock*) present_terminal omarchy-refresh-hyprlock ;; *Hyprsunset*) present_terminal omarchy-refresh-hyprsunset ;; *Plymouth*) present_terminal omarchy-refresh-plymouth ;; *Swayosd*) present_terminal omarchy-refresh-swayosd ;; + *Tmux*) present_terminal omarchy-refresh-tmux ;; *Walker*) present_terminal omarchy-refresh-walker ;; *Waybar*) present_terminal omarchy-refresh-waybar ;; *) show_update_menu ;;