Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
d8068c8
Replace YT6801 DKMS driver
AFOliveira Sep 1, 2026
a72c1c5
Make YT6801 migration retry-safe
AFOliveira Sep 3, 2026
2cd4ff8
Propagate package discovery failures before removal
AFOliveira Sep 6, 2026
f1ec4e5
Verify YT6801 cutover before retiring the vendor driver
AFOliveira Sep 6, 2026
a2c9a75
Keep YT6801 fallback through hardware reruns
AFOliveira Sep 7, 2026
c1d8113
Remove standard SSH allow rules when disabling SSH
AFOliveira Sep 23, 2026
70e1c42
Test SSH firewall rule removal and failures
AFOliveira Sep 23, 2026
ec72feb
Remove saved fingerprint templates for the invoking user
AFOliveira Sep 23, 2026
05ee744
Test fingerprint template cleanup and account boundaries
AFOliveira Sep 23, 2026
f661789
Resolve fingerprint sudo callers strictly by UID
AFOliveira Sep 24, 2026
409e715
Remove SSH service limits and application firewall rules
AFOliveira Sep 24, 2026
8f90018
Test fingerprint cleanup with numeric username collisions
AFOliveira Sep 24, 2026
1ee5934
Test SSH service and application firewall cleanup
AFOliveira Sep 24, 2026
862aac3
Run fingerprint removal fixtures as real nonroot callers
AFOliveira Sep 26, 2026
77f1d0d
Add SSH Agent (gcr-ssh-agent) as an optional service install (#9399)
carletex Sep 28, 2026
d389ed7
Nudge running Hunk sessions to pick up new theme colors (#13518)
dhh Sep 28, 2026
fdfec2c
Read the default browser from mimeapps.list when launching (#13520)
dhh Sep 28, 2026
e42094b
Hand the terminal launcher the focused window's pid from Lua (#13521)
dhh Sep 28, 2026
04f01ba
Collapse identical notifications from the same sender into one toast …
dhh Sep 28, 2026
7971de1
Hand browser and web app launches to the running browser directly (#1…
dhh Sep 28, 2026
f989c75
Add a no-animations mode, on by default in VMs (#13550)
dhh Sep 28, 2026
89867af
Get the bash prompt up ~30ms sooner (#13591)
dhh Sep 28, 2026
cd703cf
Hold polkit face chrome still when animations are off
cursoragent Sep 28, 2026
c30a948
Read Codex limits without waiting on account/read (#13733)
dhh Sep 29, 2026
f9f9863
Change the aether nvim part to the omacom org
bjarneo Sep 29, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions bin/omarchy-agent-usage-codex
Original file line number Diff line number Diff line change
Expand Up @@ -544,12 +544,20 @@ def fetch_codex_rpc():
rpc_request(proc, 1, "initialize", {"clientInfo": {"name": "omarchy-agent-usage", "version": "1"}}, timeout=8)
proc.stdin.write(json.dumps({"method": "initialized", "params": {}}) + "\n")
proc.stdin.flush()
account_msg = rpc_request(proc, 2, "account/read", timeout=4)
limits_msg = rpc_request(proc, 3, "account/rateLimits/read", timeout=4)

account = (account_msg.get("result") or {}).get("account") or {}
limits_msg = rpc_request(proc, 2, "account/rateLimits/read", timeout=8)
limits = (limits_msg.get("result") or {}).get("rateLimits") or {}
plan = limits.get("planType") or account.get("planType") or account.get("type") or ""
plan = limits.get("planType") or ""

# The limits name the plan themselves. account/read is only a fallback
# for when they don't, and never a reason to lose them: Codex 0.158's
# app-server can leave it unanswered for good.
if not plan:
try:
account_msg = rpc_request(proc, 3, "account/read", timeout=2)
account = (account_msg.get("result") or {}).get("account") or {}
plan = account.get("planType") or account.get("type") or ""
except TimeoutError:
pass
result["tierLabel"] = str(plan) if plan else ""

for window in (limits.get("primary"), limits.get("secondary")):
Expand Down
48 changes: 48 additions & 0 deletions bin/omarchy-cmd-browser-handoff
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
#!/bin/bash

# omarchy:summary=Hand a command line to the running Chromium-based browser
# omarchy:args=<browser-command> [browser-args...]
# omarchy:hidden=true

# A second browser process spends ~165ms starting up only to pass its command
# line to the running one over the profile's singleton socket, then exits. Send
# it there directly, and fail when no browser acknowledges it so the caller can
# launch one instead.
config="${XDG_CONFIG_HOME:-$HOME/.config}"

# Only the browsers themselves: a wrapper in their place may pick a profile or
# add flags of its own, which only running it can honour.
case $(type -P "$1") in
/usr/bin/chromium) profile=chromium flags=chromium-flags.conf ;;
/usr/bin/google-chrome-stable) profile=google-chrome flags=chrome-flags.conf ;;
/usr/bin/brave) profile=BraveSoftware/Brave-Browser flags=brave-flags.conf ;;
/usr/bin/brave-origin) profile=BraveSoftware/Brave-Origin flags=brave-origin-flags.conf ;;
/usr/bin/microsoft-edge-stable) profile=microsoft-edge flags=microsoft-edge-stable-flags.conf ;;
*) exit 1 ;;
esac
shift

# The running browser already has the process flags Omarchy ships in the flags
# file. Any other flag there may be meant for each launch, and a data directory
# from the environment is another browser, so leave those to the launcher.
if [[ -n ${CHROME_USER_DATA_DIR:-}${CHROME_CONFIG_HOME:-} ]] ||
cat "/etc/$flags" "$config/$flags" 2>/dev/null | sed 's/#.*//' | tr -s '[:space:]' '\n' |
grep -vE '^(--(ozone-platform|ozone-platform-hint|password-store|enable-features|load-extension)=.*)?$' | grep -q .; then
exit 1
fi

for arg in "$@"; do
[[ $arg == --user-data-dir* ]] && exit 1
done

# The socket lives in a /tmp dir, which another user could recreate once a
# crashed browser's is cleaned away, so only a socket of our own gets the URL.
socket="$config/$profile/SingletonSocket"
[[ -S $socket && -O $socket ]] || exit 1

reply=$({
printf 'START\0%s\0browser' "$PWD"
printf '\0%s' "$@"
} | socat -t2 - "UNIX-CONNECT:$socket" 2>/dev/null)

[[ $reply == "ACK" ]]
58 changes: 58 additions & 0 deletions bin/omarchy-cmd-default-browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
#!/bin/bash

# omarchy:summary=Print the desktop entry ID of the default web browser
# omarchy:hidden=true

# Read the http handler from the config-dir mimeapps.list files the way xdg-mime
# does, desktop-specific list first, taking the first listed entry that is
# installed. xdg-settings reaches the same answer through several shell scripts
# in ~70ms, which every browser and web app launch would otherwise pay.
IFS=: read -ra data_dirs <<<"${XDG_DATA_HOME:-$HOME/.local/share}:${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
IFS=: read -ra config_dirs <<<"${XDG_CONFIG_HOME:-$HOME/.config}:${XDG_CONFIG_DIRS:-/etc/xdg}"
IFS=: read -ra desktops <<<"${XDG_CURRENT_DESKTOP:-}"

# Installed means the command of the entry the launchers will read, the first
# one found, still resolves: an entry of Omarchy's own can outlive the browser
# it launched.
installed() {
local data_dir command

for data_dir in "${data_dirs[@]}"; do
[[ -r $data_dir/applications/$1 ]] || continue
command=$(sed -n 's/^Exec=\([^ ]*\).*/\1/p' "$data_dir/applications/$1" | head -1)
[[ -n $command ]] && command -v "$command" >/dev/null
return
done

return 1
}

for config_dir in "${config_dirs[@]}"; do
for desktop in "${desktops[@]}" ""; do
list="$config_dir/${desktop:+${desktop,,}-}mimeapps.list"
[[ -f $list ]] || continue

entries=$(awk '
/^\[Default Applications\]/ { section = 1; next }
/^\[/ { section = 0 }
section && index($0, "x-scheme-handler/http=") == 1 { print substr($0, 23); exit }
' "$list")

IFS=';' read -ra entries <<<"$entries"
for entry in "${entries[@]}"; do
if [[ -n $entry ]] && installed "$entry"; then
echo "$entry"
exit 0
fi
done
done
done

# Nothing set in a config dir: let xdg-settings search the data dirs and caches.
# It consults $BROWSER too, which the session points back at omarchy-launch-browser.
browser=$(env -u BROWSER xdg-settings get default-web-browser 2>/dev/null)
if [[ -z $browser ]]; then
browser=$(xdg-mime query default x-scheme-handler/https 2>/dev/null)
fi

[[ -n $browser ]] && echo "$browser"
3 changes: 2 additions & 1 deletion bin/omarchy-cmd-terminal-cwd
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#!/bin/bash

# omarchy:summary=Print the current working directory of the active terminal window
# omarchy:args=[terminal-pid]
# omarchy:hidden=true

terminal_pid=$(hyprctl activewindow | awk '/pid:/ {print $2}')
terminal_pid=${1:-$(hyprctl activewindow | awk '/pid:/ {print $2}')}
kitty_socket="$XDG_RUNTIME_DIR/omarchy-kitty-$terminal_pid"
cwd=""

Expand Down
5 changes: 5 additions & 0 deletions bin/omarchy-hw-vm
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash

# omarchy:summary=Returns true when running in a virtual machine.

systemd-detect-virt --vm --quiet
13 changes: 6 additions & 7 deletions bin/omarchy-launch-browser
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,7 @@
# omarchy:summary=Launch the default browser as determined by xdg-settings.
# omarchy:args=[url]

default_browser=$(env -u BROWSER xdg-settings get default-web-browser)
if [[ -z $default_browser ]]; then
default_browser=$(xdg-mime query default x-scheme-handler/https)
fi
default_browser=$(omarchy-cmd-default-browser)
browser_exec=$(sed -n 's/^Exec=\([^ ]*\).*/\1/p' {~/.local,~/.nix-profile,/usr}/share/applications/$default_browser 2>/dev/null | head -1)

if $browser_exec --help 2>/dev/null | grep -q MOZ_LOG; then
Expand All @@ -17,9 +14,11 @@ else
private_flag="--incognito"
fi

systemd-run --user --quiet --collect --unit="omarchy-browser-$(date +%s%N)" \
--property=StandardOutput=null --property=StandardError=null \
uwsm-app -- "$browser_exec" "${@/--private/$private_flag}"
if ! omarchy-cmd-browser-handoff "$browser_exec" "${@/--private/$private_flag}"; then
systemd-run --user --quiet --collect --unit="omarchy-browser-$(date +%s%N)" \
--property=StandardOutput=null --property=StandardError=null \
uwsm-app -- "$browser_exec" "${@/--private/$private_flag}"
fi

url=""
for argument in "$@"; do
Expand Down
10 changes: 8 additions & 2 deletions bin/omarchy-launch-terminal
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
#!/bin/bash

# omarchy:summary=Launch a terminal in the active terminal's current directory
# omarchy:args=[command...]
# omarchy:args=[--pid=<terminal-pid>] [command...]

exec setsid uwsm-app -- xdg-terminal-exec --dir="$(omarchy-cmd-terminal-cwd)" "$@"
pid=""
if [[ ${1:-} == --pid=* ]]; then
pid=${1#--pid=}
shift
fi

exec setsid uwsm-app -- xdg-terminal-exec --dir="$(omarchy-cmd-terminal-cwd "$pid")" "$@"
10 changes: 6 additions & 4 deletions bin/omarchy-launch-webapp
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@
# omarchy:summary=Launch a URL as a web app in the default supported browser
# omarchy:args=<url>

# The session sets BROWSER to omarchy-launch-browser, which sends xdg-settings
# down a slower path (~100ms against ~30ms) to the same answer.
browser=$(env -u BROWSER xdg-settings get default-web-browser)
browser=$(omarchy-cmd-default-browser)

case $browser in
google-chrome* | brave* | microsoft-edge* | opera* | vivaldi* | helium*) ;;
*) browser="chromium.desktop" ;;
esac

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}"
browser_exec=$(sed -n 's/^Exec=\([^ ]*\).*/\1/p' {~/.local,~/.nix-profile,/usr}/share/applications/$browser 2>/dev/null | head -1)

if ! omarchy-cmd-browser-handoff "$browser_exec" --app="$1" "${@:2}"; then
exec setsid uwsm-app -- $browser_exec --app="$1" "${@:2}"
fi
5 changes: 4 additions & 1 deletion bin/omarchy-menu-keybindings
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,9 @@ hl = setmetatable({
elseif type(bind_dispatcher) == "string" and bind_dispatcher ~= "" then
kind = "exec"
arg = bind_dispatcher
elseif o and o.bind_commands and o.bind_commands[bind_dispatcher] then
kind = "exec"
arg = o.bind_commands[bind_dispatcher]
end

print(table.concat({ tostring(modmask), opts.description, key, kind, arg }, "\t"))
Expand Down Expand Up @@ -530,7 +533,7 @@ output_binding_records_uncached() {

keybindings_cache_key() {
{
printf 'v13\n'
printf 'v14\n'
hyprctl devices 2>/dev/null | grep -F 'active keymap:'
hyprctl binds 2>/dev/null
} | sha256sum | awk '{ print $1 }'
Expand Down
11 changes: 9 additions & 2 deletions bin/omarchy-pkg-drop
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,16 @@ installed=()
declare -A installed_exact=()
declare -A selected=()

if ! installed_packages=$(pacman -Qq); then
echo "Unable to query installed packages; no packages were removed." >&2
exit 1
fi

while IFS= read -r package_name; do
installed_exact[$package_name]=1
done < <(pacman -Qq)
if [[ -n $package_name ]]; then
installed_exact[$package_name]=1
fi
done <<< "$installed_packages"

for pkg in "$@"; do
if [[ -n ${installed_exact[$pkg]} && -z ${selected[$pkg]} ]]; then
Expand Down
20 changes: 19 additions & 1 deletion bin/omarchy-remove-security-fingerprint
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,22 @@

set -e

# Resolve the invoking account before changing authentication or packages.
if (( EUID == 0 )) && [[ -v SUDO_UID ]]; then
if [[ ! $SUDO_UID =~ ^[0-9]+$ ]]; then
echo "Cannot identify the invoking fingerprint user" >&2
exit 1
fi
fingerprint_user=$(/usr/bin/id -nu "+$SUDO_UID") || exit 1
else
fingerprint_user=$(/usr/bin/id -un) || exit 1
fi

if [[ -z $fingerprint_user || $fingerprint_user == "." || $fingerprint_user == ".." || $fingerprint_user == */* ]]; then
echo "Unsafe fingerprint user name" >&2
exit 1
fi


remove_pam_config() {
if grep -q pam_fprintd.so /etc/pam.d/sudo; then
Expand All @@ -31,7 +47,9 @@ echo -e "\e[32mRemoving fingerprint scanner from authentication.\n\e[0m"
remove_pam_config
remove_lock_fingerprint_pam

sudo rm -rf -- "/var/lib/fprint/$fingerprint_user"

echo "Removing fingerprint packages..."
omarchy-pkg-drop fprintd libfprint libfprint-git

echo -e "\e[32mFingerprint authentication has been completely removed.\e[0m"
echo -e "\e[32mFingerprint authentication and $fingerprint_user's local saved fingerprints have been removed.\e[0m"
14 changes: 10 additions & 4 deletions bin/omarchy-remove-security-sshd
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# omarchy:summary=Disable the OpenSSH server, close the firewall port, and optionally remove authorized keys
# omarchy:summary=Disable the OpenSSH server, remove standard firewall rules, and optionally remove authorized keys
# omarchy:requires-sudo=true

set -e
Expand All @@ -13,9 +13,15 @@ echo "Stopping and disabling the OpenSSH server..."
sudo systemctl disable --now sshd.service 2>/dev/null || true

if omarchy-cmd-present ufw; then
echo "Closing the SSH port in the firewall..."
sudo ufw --force delete limit 22/tcp >/dev/null 2>&1 || true
echo "Removing standard SSH firewall rules..."
sudo ufw --force delete limit 22/tcp >/dev/null
sudo ufw --force delete allow 22/tcp >/dev/null
sudo ufw --force delete allow ssh >/dev/null
sudo ufw --force delete limit ssh >/dev/null
sudo ufw --force delete allow to any app SSH >/dev/null
sudo ufw --force delete limit to any app SSH >/dev/null
sudo ufw reload >/dev/null
echo "Standard SSH firewall rules removed. Review custom firewall rules separately."
fi

if [[ -s $AUTHORIZED_KEYS ]]; then
Expand All @@ -28,5 +34,5 @@ if [[ -s $AUTHORIZED_KEYS ]]; then
fi
fi

echo -e "\e[32m\nThe SSH server has been disabled and its firewall port closed.\e[0m"
echo -e "\e[32m\nThe SSH server has been disabled.\e[0m"
echo "The openssh package remains installed since it also provides the ssh client."
16 changes: 16 additions & 0 deletions bin/omarchy-remove-service-ssh-agent
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

# omarchy:summary=Disable the gcr-ssh-agent SSH agent and its environment override.

# The file goes before disable reloads the manager, or the environment generator keeps exporting it.
rm -f "$HOME/.config/environment.d/90-gcr-ssh-agent.conf"
systemctl --user disable --now gcr-ssh-agent.socket 2>/dev/null || true
systemctl --user stop gcr-ssh-agent.service 2>/dev/null || true

# The socket exported SSH_AUTH_SOCK to the user manager, which outlives the agent.
if systemctl --user show-environment | grep -Fqx "SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/gcr/ssh"; then
systemctl --user unset-environment SSH_AUTH_SOCK
fi

echo ""
echo "SSH agent has been disabled. Log out and back in for it to take full effect."
17 changes: 17 additions & 0 deletions bin/omarchy-setup-security-ssh-agent
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash

# omarchy:summary=Enable an SSH agent (gcr-ssh-agent) that prompts for key passphrases graphically.

set -e

ENV_FILE="$HOME/.config/environment.d/90-gcr-ssh-agent.conf"

systemctl --user enable --now gcr-ssh-agent.socket

mkdir -p "$(dirname "$ENV_FILE")"
echo 'SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/gcr/ssh' >"$ENV_FILE"

echo ""
echo "SSH agent has been enabled. Log out and back in to make it available everywhere."
echo "The first use of a passphrase-protected key opens a dialog, with the option to"
echo "remember the passphrase in the keyring."
1 change: 1 addition & 0 deletions bin/omarchy-theme-set
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,7 @@ post_theme_commands=(
omarchy-restart-helix
omarchy-theme-set-foot
omarchy-theme-set-tmux
omarchy-theme-set-hunk
omarchy-theme-set-gnome
omarchy-theme-set-pi
omarchy-theme-set-claude
Expand Down
14 changes: 14 additions & 0 deletions bin/omarchy-theme-set-hunk
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

# omarchy:summary=Tell running Hunk sessions to pick up the new terminal colors
# omarchy:hidden=true

# Hunk's default terminal theme re-reads the terminal palette on SIGWINCH. Terminals reload
# their colors in parallel with this hook, so nudge once now and once after they have settled;
# Hunk only repaints when the palette actually changed.

if pgrep -x hunk >/dev/null; then
pkill -WINCH -x hunk
sleep 1
pkill -WINCH -x hunk
fi
22 changes: 22 additions & 0 deletions bin/omarchy-toggle-animations
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash

# omarchy:summary=Toggle animations, transparency and other effects that are slow without a GPU
# omarchy:args=[toggle|on|off]
# omarchy:examples=omarchy toggle animations | omarchy toggle animations off | omarchy toggle animations on

# The flag records animations being off, so on and off swap on the way through.
case ${1:-toggle} in
toggle) omarchy-hyprland-toggle no-animations toggle ;;
on) omarchy-hyprland-toggle no-animations off ;;
off) omarchy-hyprland-toggle no-animations on ;;
*)
echo "Usage: omarchy-toggle-animations [toggle|on|off]" >&2
exit 1
;;
esac

if omarchy-hyprland-toggle-enabled no-animations; then
omarchy-notification-send -g 󰕟 "Animations disabled"
else
omarchy-notification-send -g 󰕟 "Animations enabled"
fi
Loading