diff options
-rwxr-xr-x | browser | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -1,5 +1,9 @@ #!/usr/bin/env zsh +platform=$(uname) + +if [[ "$platform" == "Linux" ]]; then + # To use mpv for youtube links if [[ $1 != "" ]]; then if printf $1 2>/dev/null | grep -q "youtube.com"; then @@ -31,3 +35,16 @@ case "$1" in TZ=UTC GDK_SCALE=$SCALE GDK_DPI_SCALE=$SCALE /usr/bin/env $bin -new-tab $@ ;; esac + +elif [[ "$platform" == "Darwin" ]]; then +case "$1" in + *tmp/pks/mutt/*) + cp $1 $1.html + open -j -a "Firefox" "$1.html" + ;; + *) + open -j -a "Firefox" "$1" + ;; +esac +return 0 +fi |