~mil/sxmo-utils

ref: 103a6612f3987807b1abb99621d79fb6d59ff5cb sxmo-utils/scripts/appscripts/sxmo_websearch.sh -rwxr-xr-x 381 bytes
103a6612Stacy Harper Fix autorotation script 11 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/usr/bin/env sh

# include common definitions
# shellcheck source=scripts/core/sxmo_common.sh
. "$(dirname "$0")/sxmo_common.sh"

sxmo_keyboard.sh open
SEARCHQUERY="$(
	echo "Close Menu" | sxmo_dmenu.sh -p "Search:"
)"
sxmo_keyboard.sh close
[ "Close Menu" = "$SEARCHQUERY" ] && exit 0

echo "$SEARCHQUERY" | grep . || exit 0

$BROWSER "https://duckduckgo.com/?q=${SEARCHQUERY}"