#!/bin/sh

DIR=/usr/share/lucidor

if which xulrunner-2.0; then
    xulrunner-2.0 $DIR/application.ini "$@";
elif which xulrunner-1.9.2; then
    xulrunner-1.9.2 $DIR/application.ini "$@";
elif which xulrunner-1.9.1; then
    xulrunner-1.9.1 $DIR/application.ini "$@";
elif which xulrunner-1.9; then
    xulrunner-1.9 $DIR/application.ini "$@";
elif which xulrunner; then
    xulrunner $DIR/application.ini "$@";
elif which firefox; then
    firefox -app $DIR/application.ini "$@";
elif which iceweasel; then
    iceweasel -app $DIR/application.ini "$@";
elif which abrowser; then
    abrowser -app $DIR/application.ini "$@";
else
    echo "Could not find XULRunner runtime engine."
    exit 1;
fi
