summaryrefslogtreecommitdiff
path: root/url_handler.sh
diff options
context:
space:
mode:
author53hornet <atc@53hor.net>2021-10-26 08:30:58 -0400
committer53hornet <atc@53hor.net>2021-10-26 08:30:58 -0400
commit88784a46b3f0faf3c85010cbc3e2fe3c26939879 (patch)
treeab2183bdb87f325f377a9caf6e0bc7e867c23af2 /url_handler.sh
parent7f1adf1900081409214e83a59369967ceaac441f (diff)
downloadscripts-88784a46b3f0faf3c85010cbc3e2fe3c26939879.tar.xz
scripts-88784a46b3f0faf3c85010cbc3e2fe3c26939879.zip
add wallpaper script with display from imagemagick, update dockd
Diffstat (limited to 'url_handler.sh')
-rwxr-xr-xurl_handler.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/url_handler.sh b/url_handler.sh
index 5ae6c59..55d225c 100755
--- a/url_handler.sh
+++ b/url_handler.sh
@@ -83,6 +83,7 @@ handle_youtube() {
# Main
URL=$1
+[ -n "$URL" ] || URL=$(xclip -o)
[ -n "$URL" ] || URL=$(get_url)
[ -n "$URL" ] || exit
echo "$URL"
@@ -90,9 +91,9 @@ echo "$URL"
case $URL in
*youtube.com*) handle_youtube "$URL" ;;
*youtu.be*) handle_youtube "$URL" ;;
- *ytsearch:*) handle_youtube "$URL" ;;
- *mailto*) mutt "$URL" ;;
- *http?*) $BROWSER "$URL" ;;
+ ytsearch:*) handle_youtube "$URL" ;;
+ mailto*) mutt "$URL" ;;
+ http?*) $BROWSER "$URL" ;;
*)
$BROWSER --search "$URL"
esac