| 123456789101112131415 |
- #!/bin/bash
- result=$(compgen -c | sort -u | bemenu -l 10 -p "🔍" --counter always -c -W 0.4 -B 5 \
- --fixed-height -H 22 --fn 'B612 11' \
- --bdr "#323232" --tf "#FFFFFF" --hf "#FFFFFF")
- [ -z "$result" ] && exit 0
- if command -v "${result%% *}" &>/dev/null; then
- exec $result
- else
- query=$(python3 -c "import urllib.parse, sys; print(urllib.parse.quote_plus(sys.argv[1]))" "$result")
- xdg-open "https://duckduckgo.com/?q=$query" &
- sleep 0.5
- swaymsg '[app_id="google-chrome"] focus'
- fi
|