diff options
Diffstat (limited to 'dmenu/plumb')
-rwxr-xr-x | dmenu/plumb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/dmenu/plumb b/dmenu/plumb index 13cfca8..c0d98f3 100755 --- a/dmenu/plumb +++ b/dmenu/plumb @@ -90,7 +90,11 @@ functions="$functions duckduckgo" duckduckgo () { exec $WEB_BROWSER "https://duckduckgo.com/?q=$sel"; } +# TODO add other search engines +if (( $(printf '%s' "$sel" | wc -m) > 100 )); then + sel='selected text' +fi function="$(printf '%s\n' $functions | dmenu -i -p "Plumb $sel to:" -l 50)" if test -n "$function"; then |