Results 1 to 2 of 2

Thread: Scripting installation of firefox extensions

  1. #1
    Join Date
    Jun 2007
    Beans
    427

    Question Scripting installation of firefox extensions

    I'm trying to figure out how to install firefox xpi extensions from a scripted environment and running into trouble. My understanding is that you can do this by running the following command:

    Code:
    firefox -install-global-extension "<path-to-extension>\extname.xpi"
    Unfortunately, all this does is start firefox. Anybody have any idea why this doesn't work? Here's my current script:

    Code:
    TMPDIR=`mktemp -d`
    cd $TMPDIR
    
    # Grab flashblock
    wget https://addons.mozilla.org/en-US/firefox/downloads/latest/433/addon-433-latest.xpi?src=addondetail
    
    # Grab adblock plus
    wget https://addons.mozilla.org/en-US/firefox/downloads/latest/1865/addon-1865-latest.xpi?src=addondetail
    
    for FILE in $TMPDIR/*.xpi ; do
    	firefox -install-global-extension "$FILE"
    done
    I've tried executing these commands manually just to confirm, but it just doesn't work.

  2. #2
    Join Date
    May 2008
    Beans
    14
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: Scripting installation of firefox extensions

    Try it with sudo. e.g. sudo <your script>
    or sudo firefox -install-global-extension "<path-to-extension>\extname.xpi"

    Alternatively, look here for a method avoiding -install-global-extension altogether.
    -> http://ubuntuforums.org/showpost.php...6&postcount=11
    Last edited by kitrule; January 18th, 2011 at 11:43 PM.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •