added scripts + config stuff

This commit is contained in:
2025-05-02 22:42:39 -07:00
parent 989b4d473b
commit 674f083980
3 changed files with 58 additions and 2 deletions

View File

@@ -16,6 +16,8 @@ set $term alacritty
# Application Launcher
set $menu bemenu-run -p "Run:" -l 10 -c -M 500 --fn 'Monospace 14' --tb '#1d2021' --tf '#d8a657' --fb '#1d2021' --ff '#d4be98' --cb '#7daea3' --cf '#1d2021' --nb '#1d2021' --nf '#d4be98' --hb '#7daea3' --hf '#1d2021' --sb '#7daea3' --sf '#1d2021' --ab '#1b1b1b' --af '#d4be98' --scb '#1d2021' --scf '#d4be98'
#######################
# GENERAL KEYBINDS
#######################
@@ -201,7 +203,7 @@ bindsym $mod+Shift+0 move container to workspace $ws7
# Unused $mod+<key> bindings
# bindsym $mod+a exec <command>
# bindsym $mod+c exec
# bindsym $mod+m exec <command>
bindsym $mod+m exec ~/.local/bin/man.sh
# bindsym $mod+n exec <command>
# bindsym $mod+o exec <command>
# bindsym $mod+q exec <command>
@@ -218,7 +220,7 @@ bindsym $mod+Shift+0 move container to workspace $ws7
# bindsym $mod+equal exec <command>
# bindsym $mod+bracketleft exec <command>
# bindsym $mod+bracketright exec <command>
# bindsym $mod+semicolon exec <command>
bindsym $mod+semicolon exec ~/.local/bin/unimenu.sh
# bindsym $mod+apostrophe exec <command>
# bindsym $mod+comma exec <command>
# bindsym $mod+period exec <command>

18
.local/bin/man.sh Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/sh
TERMINAL="alacritty"
# Grab man entries
man_entries=$(apropos . | awk -F ' - ' '{print $1}' | sort -u)
# Show in bemenu
selection=$(printf '%s\n' "$man_entries" | \
bemenu -p "man:" -l 10 -c -M 500 \
--fn 'Monospace 14' \
--tb '#1d2021' --tf '#d8a657' --fb '#1d2021' --ff '#d4be98' \
--cb '#7daea3' --cf '#1d2021' --nb '#1d2021' --nf '#d4be98' \
--hb '#7daea3' --hf '#1d2021' --sb '#7daea3' --sf '#1d2021' \
--ab '#1b1b1b' --af '#d4be98' --scb '#1d2021' --scf '#d4be98')
# Open the man page in the terminal
[ -n "$selection" ] && "$TERMINAL" -e man "$(echo "$selection" | awk '{print $1}')"

36
.local/bin/unimenu.sh Executable file
View File

@@ -0,0 +1,36 @@
#!/bin/sh
MENU="📚 Dictionary\n🌍 Translate\n📖 Man Page\n🔐 Passwords\n📝 Notes\n🖼 Emoji Picker"
choice=$(printf "$MENU" | \
bemenu -p "Choose:" -l 10 -c -M 500 \
--fn 'Monospace 14' \
--tb '#1d2021' --tf '#d8a657' --fb '#1d2021' --ff '#d4be98' \
--cb '#7daea3' --cf '#1d2021' --nb '#1d2021' --nf '#d4be98' \
--hb '#7daea3' --hf '#1d2021' --sb '#7daea3' --sf '#1d2021' \
--ab '#1b1b1b' --af '#d4be98' --scb '#1d2021' --scf '#d4be98')
case "$choice" in
"📚 Dictionary")
word=$(bemenu -p "Define:")
[ -n "$word" ] && alacritty -e sdcv "$word"
;;
"🌍 Translate")
phrase=$(bemenu -p "Translate:")
[ -n "$phrase" ] && alacritty -e trans ":en" "$phrase"
;;
"📖 Man Page")
~/.local/bin/man.sh
;;
"🔐 Passwords")
passmenu # or gopass fzf if you're using gopass
;;
"📝 Notes")
note=$(bemenu-run -p "Note:")
[ -n "$note" ] && echo "- $(date): $note" >> ~/notes/quick.md
;;
"🖼 Emoji Picker")
wtype $(awk '{print $1, $0}' ~/.local/share/chars/emojis* | bemenu -p Emoji: -l 25 -c -M 500 --fn 'Noto Color Emoji,Monospace 14' --tb '#1d2021' --tf '#d8a657' --fb '#1d2021' --ff '#d4be98' --cb '#7daea3' --cf '#1d2021' --nb '#1d2021' --nf '#d4be98' --hb '#7daea3' --hf '#1d2021' --sb '#7daea3' --sf '#1d2021' --ab '#1b1b1b' --af '#d4be98' --scb '#1d2021' --scf '#d4be98' | awk '{print $1}')
;;
esac