From 0b631340b419d1d0beddf44fcc55e4d1b84fc541 Mon Sep 17 00:00:00 2001 From: mdheller <21163552+mdheller@users.noreply.github.com> Date: Fri, 17 Apr 2026 22:29:33 -0400 Subject: [PATCH 1/3] linux-dev/workstation-v0: add GNOME Albert hotkey configurator --- .../workstation-v0/gnome/albert-hotkey.sh | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 profiles/linux-dev/workstation-v0/gnome/albert-hotkey.sh diff --git a/profiles/linux-dev/workstation-v0/gnome/albert-hotkey.sh b/profiles/linux-dev/workstation-v0/gnome/albert-hotkey.sh new file mode 100644 index 0000000..e148601 --- /dev/null +++ b/profiles/linux-dev/workstation-v0/gnome/albert-hotkey.sh @@ -0,0 +1,50 @@ +#!/usr/bin/env bash +set -euo pipefail + +# Configure a GNOME custom keybinding for Albert. +# We bind Super+Space to `albert toggle` by default. +# We also avoid collision with GNOME input-source switching by moving that to Alt+Shift. + +info(){ printf "INFO: %s\n" "$*" >&2; } +warn(){ printf "WARN: %s\n" "$*" >&2; } + +have(){ command -v "$1" >/dev/null 2>&1; } + +is_gnome(){ + [[ "${XDG_CURRENT_DESKTOP:-}" == *GNOME* ]] && return 0 + [[ "${DESKTOP_SESSION:-}" == *gnome* ]] && return 0 + return 1 +} + +main(){ + if ! have gsettings; then + warn "gsettings missing; cannot set hotkey" + exit 0 + fi + + if ! is_gnome; then + warn "GNOME not detected; skipping hotkey" + exit 0 + fi + + # Move input source switching away from Super+Space (macOS uses Cmd+Space for search). + # GNOME typically uses: org.gnome.desktop.wm.keybindings switch-input-source / switch-input-source-backward + gsettings set org.gnome.desktop.wm.keybindings switch-input-source "['Shift_L']" || true + gsettings set org.gnome.desktop.wm.keybindings switch-input-source-backward "['Shift_R']" || true + + # Add a custom keybinding for Albert. + # Path style: /org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ + local base="/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/" + local custom0="${base}custom0/" + + gsettings set org.gnome.settings-daemon.plugins.media-keys custom-keybindings "['${custom0}']" || true + + gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:${custom0} name "Albert" || true + gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:${custom0} command "albert toggle" || true + gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:${custom0} binding "space" || true + + info "Albert hotkey set: Space → albert toggle" + info "Input source switching moved to Alt+Shift (L/R)" +} + +main "$@" From 6db2f0aef3cd4044d2c51781c950f13ab9b6a99a Mon Sep 17 00:00:00 2001 From: mdheller <21163552+mdheller@users.noreply.github.com> Date: Fri, 17 Apr 2026 22:46:35 -0400 Subject: [PATCH 2/3] linux-dev/workstation-v0: wire Albert hotkey into installer --- profiles/linux-dev/workstation-v0/install.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/profiles/linux-dev/workstation-v0/install.sh b/profiles/linux-dev/workstation-v0/install.sh index a742455..36b6936 100644 --- a/profiles/linux-dev/workstation-v0/install.sh +++ b/profiles/linux-dev/workstation-v0/install.sh @@ -77,6 +77,16 @@ apply_gnome_extensions(){ fi } +apply_albert_hotkey(){ + local script="$PROFILE_DIR/gnome/albert-hotkey.sh" + if [[ -x "$script" ]]; then + info "Setting Albert hotkey (best-effort)" + "$script" || warn "Albert hotkey setup failed (non-fatal)" + else + warn "Albert hotkey script not found: $script" + fi +} + main(){ [[ -f "$MANIFEST" ]] || { err "manifest missing: $MANIFEST"; exit 2; } install_system @@ -84,6 +94,7 @@ main(){ install_shell_spine apply_gnome_baseline apply_gnome_extensions + apply_albert_hotkey info "installed workstation-v0 (linux-dev)" info "next: ./doctor.sh" } From 55e01c15106ff1fd6a9402104e2dab353d29882c Mon Sep 17 00:00:00 2001 From: mdheller <21163552+mdheller@users.noreply.github.com> Date: Sat, 18 Apr 2026 08:26:12 -0400 Subject: [PATCH 3/3] linux-dev/workstation-v0: doctor reports albert hotkey binding --- profiles/linux-dev/workstation-v0/doctor.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/profiles/linux-dev/workstation-v0/doctor.sh b/profiles/linux-dev/workstation-v0/doctor.sh index 8a7a846..58c1563 100644 --- a/profiles/linux-dev/workstation-v0/doctor.sh +++ b/profiles/linux-dev/workstation-v0/doctor.sh @@ -95,6 +95,19 @@ main(){ if gnome_detect; then if have gsettings; then info "gnome: detected; gsettings present" + + # best-effort visibility of albert hotkey binding + local base="/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/" + local custom0="${base}custom0/" + local bindings + bindings=$(gsettings get org.gnome.settings-daemon.plugins.media-keys custom-keybindings || true) + info "gnome: custom-keybindings = ${bindings}" + local hk + hk=$(gsettings get org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:${custom0} binding 2>/dev/null || true) + if [[ -n "$hk" ]]; then + info "gnome: albert binding = ${hk}" + fi + else warn "gnome: detected but gsettings missing" fi