blob: 0d9deb88473ffd1fdbf6a0496897c633fb519857 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
#!/bin/bash
configs=(
"hypr:$HOME/.config/hypr/"
"scripts:$HOME/.config/scripts/"
"kitty:$HOME/.config/kitty/kitty.conf"
"fish:$HOME/.config/fish/config.fish"
"btop:$HOME/.config/btop/btop.conf"
"fastfetch:$HOME/.config/fastfetch/config.jsonc"
"fuzzel:$HOME/.config/fuzzel/fuzzel.ini"
"dunst:$HOME/.config/dunst/dunstrc"
)
choice=$(printf "%s\n" "${configs[@]}" | cut -d':' -f1 | fuzzel -d -p "> ")
[[ -z "$choice" ]] && exit
for item in "${configs[@]}"; do
if [[ "$item" == "$choice:"* ]]; then
path="${item#*:}"
break
fi
done
if [ -e "$path" ]; then
zeditor "$path"
else
notify-send "error" "file not found: $path"
fi
|