3 # This script is used to add and remove our extension from the Firefox
4 # directory, and is run from 'triggers' when Firefox is installed or
5 # upgraded, as well as when our package is installed.
9 d=/usr/GET_LIBDIR/mozilla-firefox
11 if [ "$1" = "install" ] ; then
12 # Add symlink to the firefox directory that looks like it is part of a
13 # currently installed package
14 if [ -e "$d/firefox-bin" -a -d "$d/extensions" -a ! -L "$d/extensions/firefox@mugshot.org" ] ; then
15 ln -s /usr/GET_LIBDIR/mugshot/firefox "$d/extensions/firefox@mugshot.org"
17 elif [ "$1" = "remove" ] ; then
18 # Remove the symlink we've created
19 if [ -L "$d/extensions/firefox@mugshot.org" ] ; then
20 rm "$d/extensions/firefox@mugshot.org"
23 echo "Usage firefox-update.sh [install/remove]"