From a43b48b5e61078c3472a97a413988f9853fe3115 Mon Sep 17 00:00:00 2001 From: Patrick Simianer
Date: Tue, 12 Dec 2017 00:41:11 +0100 Subject: open-in-browser: fix --- open-in-browser | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'open-in-browser') diff --git a/open-in-browser b/open-in-browser index b66c590..bb30c64 100755 --- a/open-in-browser +++ b/open-in-browser @@ -1,7 +1,11 @@ #!/usr/bin/env zsh if [[ $(uname) == "Darwin" ]]; then - osascript -e "tell application \"Firefox\" to open location \"$1\"" + if [[ $1 == http://* || $1 == https://* ]]; then + osascript -e "tell application \"Firefox\" to open location \"$1\"" + else + open -a Firefox $1 + fi else firefox "$1" &>/dev/null & fi -- cgit v1.2.3