I was bored, so I decided to make a shell script to automate the process of making a firefox extension work with all versions.
It was quite a learning experience, being my first decent shell script.Note that in all likelihood it sucks, and barely works. But it *does* do what it’s supposed to do. At least on my computer.
There are two ways to do it. Installation or no-install. For either one, download this. It is the actual script. To use it, put it and the .xpi extension (see my previous post on this) in the same folder. Note that there must be only ONE .xpi file in that directory. More than one will result in bad results and deleted files (the source extension is deleted).
Now, run ’sudo chmod +x compatiblizer’ in that directory. Then, changing it is as easy as ./compatibilizer. The original extension will be deleted, and a new one, called compatibilized-ffx-extension.xpi.
Just install that as usual in Firefox. Again, see the original article for details.
For the install route, download this. Put it wherever you want, as long it is in the same dir as the other one. Now run ’sudo chmod +x install_compatibilizer’.Now run ’sudo ./install_compatibilizer’ to install it. These two files can now be deleted, or whatever you want to do with them.
To convert extensions, simply put the extension into a directory by itself and run compatibilizer while in that directory. The same result will be produced. This can be used forever now.
Now doing this is a *bit* easier, or at least more informative.
Note that older extensions tend to not work quite as well with the Betas as the Alphas. Bigger difference, I guess. Many do still work, and just need this change to run.
The original article (that this automates.
If you have problems, leave a comment. If you like it, leave a comment. Just leave a comment.

Full contents of script:
#!/bin/bash
#Daniel’s Firefox extension compatibilizer!
#Warning! This script is untested on anything but my computer. However, it uses only standard system tools, so it should be fine anywhere.echo ‘Starting extension compatibilizer.’
echo ‘Unzipping to temporary directory.’
mkdir temp
unzip -q *.xpi -d temp/
rm *.xpi
cd temp/
cp install.rdf install.rdf.backup
echo ‘Replacing max version number…’
sed ’s|.*|5.0|’ install.rdf
echo ‘Done replacing max version number’
zip -q -r temp.xpi *
echo ‘Remade extension.’
echo ‘Moving extension.’
mv temp.xpi ../compatibilized-ffx-extension.xpi
echo ‘Extension moved. Deleting temp dirs.’
cd ../
rm -r temp
echo ‘Done! Install it and have fun.’
Filed under: Uncategorized
[...] If you are using linux, I scripted this in bash to make it a bit easier. See that article here. [...]
[...] More on installing incompatible Firefox addons. [...]
Wouldn’t it be safer to pass in the name of the package as an argument? This would die horribly if there was more than one file matching *.xpi
Yeah, I didn’t know how when I wrote this. I’ll rewrite it in a few days to add that now that I know how. For the moment I warn against that: ‘Note that there must be only ONE .xpi file in that directory’ is what I have now.
Thanks for reminding me!
[...] Thanks for getting me to do this, Tyler! [...]