mirror of
https://github.com/basecamp/omarchy.git
synced 2026-02-17 15:25:37 +00:00
Add --print option to output keybindings to terminal
This commit is contained in:
@@ -212,18 +212,26 @@ prioritize_entries() {
|
|||||||
cut -f2-
|
cut -f2-
|
||||||
}
|
}
|
||||||
|
|
||||||
monitor_height=$(hyprctl monitors -j | jq -r '.[] | select(.focused == true) | .height')
|
output_keybindings() {
|
||||||
menu_height=$((monitor_height * 40 / 100))
|
build_keymap_cache
|
||||||
|
|
||||||
build_keymap_cache
|
{
|
||||||
|
dynamic_bindings
|
||||||
|
static_bindings
|
||||||
|
} |
|
||||||
|
sort -u |
|
||||||
|
parse_keycodes |
|
||||||
|
parse_bindings |
|
||||||
|
prioritize_entries
|
||||||
|
}
|
||||||
|
|
||||||
{
|
if [[ "$1" == "--print" || "$1" == "-p" ]]; then
|
||||||
dynamic_bindings
|
output_keybindings
|
||||||
static_bindings
|
else
|
||||||
} |
|
monitor_height=$(hyprctl monitors -j | jq -r '.[] | select(.focused == true) | .height')
|
||||||
sort -u |
|
menu_height=$((monitor_height * 40 / 100))
|
||||||
parse_keycodes |
|
|
||||||
parse_bindings |
|
output_keybindings |
|
||||||
prioritize_entries |
|
walker --dmenu -p 'Keybindings' --width 800 --height "$menu_height"
|
||||||
walker --dmenu -p 'Keybindings' --width 800 --height "$menu_height"
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user