Evgeniy
Evgeniy

Reputation: 2605

Create installable Firefox XPI for bootstrapped extension

I downloaded from addons repository a Firefox extension (url shortener), unzipped it and reworked a little bit to use another shortener service - i changed already only a url of shortening service and some names in meta - nothing of vital importance. If i try just to zip all directories and files as they are and try to install - installation fails with an alert

"This addon can't be installed - it could be corrupted"

I guess there are any troubles with zipping of it. I'm even sure, that there is a zipping problem, cause i tried to unzip the original extension, than to zip it without code changes and to install - same error alert.

Also the question is, how to create an installable XPI for the bootstrapped extension (it is:

The structure of bootstrapped extension (which i have here) is:

   /defaults
   /locale
   /resources
    harness-options.json
    locales.json
    bootstrap.js
    install.rdf
    options.xul

I use 7-zip, but it is no problem to use any another archiving software.

Thank you for any advice!

Evgeniy

Upvotes: 0

Views: 308

Answers (1)

Evgeniy
Evgeniy

Reputation: 2605

Got it done! Like it describes this answer https://stackoverflow.com/a/18992738/1992004 i zipped a whole folder, what led in error cause of a folder creation inside of archive. After i zipped only included subfolders, i got an installable xpi.

Upvotes: 0

Related Questions