From ab3b20c85f2e3f7529aa6e492b03a058323a82c8 Mon Sep 17 00:00:00 2001 From: The-Repo-Club Date: Sun, 6 Nov 2022 18:57:21 +0000 Subject: [PATCH] i3 keybinds script --- i3/.config/i3/scripts/keybinds.sh | 32 +++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/i3/.config/i3/scripts/keybinds.sh b/i3/.config/i3/scripts/keybinds.sh index 213970348..3dacaa8ef 100755 --- a/i3/.config/i3/scripts/keybinds.sh +++ b/i3/.config/i3/scripts/keybinds.sh @@ -12,7 +12,7 @@ # Created: # Wed 10 March 2021, 12:34:47 PM [GMT] # Modified: -# Fri 21 January 2022, 02:29:56 PM [GMT] +# Sun 06 November 2022, 06:52:52 PM [GMT] # # Description: # @@ -20,19 +20,19 @@ cmd="\grep -A 1 Description $HOME/.config/i3/config | sed -e s/--/\ /g" case $1 in - fzf) - cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | fzf - ;; - yad) - cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | yad --text-info --width=800 --height=800 - ;; - dmenu) - cmd="$cmd -e s/Description:\ //gI" && echo "$(eval "$cmd")" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | dmenu -l 10 -p "Search Keybind" - ;; - rofi) - cmd="$cmd -e s/Description:\ //gI" && echo "$(eval "$cmd")" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | rofi -dmenu -i -width 1000 -p "Search Keybind" - ;; - *) - cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | yad --text-info --width=800 --height=800 - ;; +fzf) + cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | fzf + ;; +yad) + cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | yad --text-info --width=800 --height=800 + ;; +dmenu) + cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | dmenu -l 10 -p "Search Keybind" + ;; +rofi) + cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | rofi -dmenu -i -width 1000 -p "Search Keybind" + ;; +*) + cmd="$cmd -e s/Description:\ //gI" && eval "$cmd" | sed -e 's/[\\$]//g' | sed -e 's/_b//g' | sed -e 's/+/ + /g' | awk '/^[a-z]/ && last {print last,$0,";"} {last=""} /^#/{last=$0}' | column -t -s ';' | yad --text-info --width=800 --height=800 + ;; esac