mirror of
https://github.com/LukeHagar/omarchy.git
synced 2025-12-09 20:47:48 +00:00
Keyboard is wrongly set after install, this is because the config moved to a dedicated input.conf and so no substitution is done.
17 lines
509 B
Bash
Executable File
17 lines
509 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Copy over the keyboard layout that's been set in Arch during install to Hyprland
|
|
conf="/etc/vconsole.conf"
|
|
hyprconf="$HOME/.config/hypr/input.conf"
|
|
|
|
layout=$(grep '^XKBLAYOUT=' "$conf" | cut -d= -f2 | tr -d '"')
|
|
variant=$(grep '^XKBVARIANT=' "$conf" | cut -d= -f2 | tr -d '"')
|
|
|
|
if [[ -n "$layout" ]]; then
|
|
sed -i "/^[[:space:]]*kb_options *=/i\ kb_layout = $layout" "$hyprconf"
|
|
fi
|
|
|
|
if [[ -n "$variant" ]]; then
|
|
sed -i "/^[[:space:]]*kb_options *=/i\ kb_variant = $variant" "$hyprconf"
|
|
fi
|