Preserve the GNOME Caps Lock behavior
This commit is contained in:
@@ -9,6 +9,7 @@ set -euo pipefail
|
||||
repo_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")/../.." && pwd)"
|
||||
page="$repo_dir/config/dot/quickshell/modules/settings/ShortcutsPage.qml"
|
||||
input="$repo_dir/config/dot/hypr/input.lua"
|
||||
schema="$repo_dir/config/dot/quickshell/config/PreferenceSchema.qml"
|
||||
|
||||
fail() {
|
||||
printf 'xkb presets contract: %s\n' "$1" >&2
|
||||
@@ -37,7 +38,9 @@ rg -Fq 'option.indexOf(prefix) !== 0' "$page" \
|
||||
|
||||
rg -Fq 'kb_variant = prefs.get("keyboardVariant", "")' "$input" \
|
||||
|| fail 'Hyprland does not replay the stored keyboard variant'
|
||||
rg -Fq 'kb_options = prefs.get("keyboardOptions", "")' "$input" \
|
||||
rg -Fq 'key: "keyboardOptions", type: "string", def: "caps:escape_shifted_capslock"' "$schema" \
|
||||
|| fail 'the shipped XKB default no longer matches the migrated GNOME behavior'
|
||||
rg -Fq 'kb_options = prefs.get("keyboardOptions", "caps:escape_shifted_capslock")' "$input" \
|
||||
|| fail 'Hyprland does not replay the stored keyboard options'
|
||||
|
||||
printf 'xkb presets contract: PASS\n'
|
||||
|
||||
Reference in New Issue
Block a user