diff options
Diffstat (limited to 'mercury-browser.sh')
-rw-r--r-- | mercury-browser.sh | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/mercury-browser.sh b/mercury-browser.sh index 0e89be023298..eac094bad6c7 100644 --- a/mercury-browser.sh +++ b/mercury-browser.sh @@ -2,26 +2,26 @@ # check microprocessor architecture level if /usr/lib/ld-linux-x86-64.so.2 --help | grep -qsE '^\s+x86-64-v3.*supported.*$' ; then - XDG_CONFIG_HOME=${XDG_CONFIG_HOME:-~/.config} + _message+=$'Enjoy the fastest Firefox fork on Earth.' +else + _message='' + _message+=$'Your processor does not support x86-64-v3.\n' + _message+=$'mercury-browser may not work on your computer.' +fi - # Allow users to override command-line options - if [[ -f $XDG_CONFIG_HOME/mercury-flags.conf ]]; then - MERCURY_USER_FLAGS="$(cat $XDG_CONFIG_HOME/mercury-flags.conf)" - fi +XDG_CONFIG_HOME=${XDG_CONFIG_HOME:-~/.config} - # Launch - exec /opt/mercury-browser/mercury $MERCURY_USER_FLAGS "$@" -else - _message='' - _message+=$'Your processor does not support x86-64-v3.\n' - _message+=$'mercury-browser will not work on your computer.' +# Allow users to override command-line options +if [[ -f $XDG_CONFIG_HOME/mercury-flags.conf ]]; then + MERCURY_USER_FLAGS="$(cat $XDG_CONFIG_HOME/mercury-flags.conf)" fi # display processor support message if tty -s ; then - echo "${_message:?}" + echo "$_message" else - notify-send -a "mercury-browser" -t 3000 "${_message:?}" + [ ! -e "$HOME/.mercury" ] && notify-send -a "mercury-browser" -t 7500 "$_message" fi -exit 1 +# Launch +exec /opt/mercury-browser/mercury $MERCURY_USER_FLAGS "$@" |