How to modify a Firefox extension and create the .xpi?

What I show you below I learned how to do yesterday and I want to share it with you because maybe you are in the same situation as me.

The point is that I installed a Extension call Screengrab, which allows us to capture the websites we visit and so on. The problem was very simple, the icon that appeared in the toolbar Firefox it broke with the design of the rest, that is, it just looked very ugly.

What does not enter my eyes ... well, that does not enter me and with that type of detail I am a bit fussy. But hey, let's get to the initial topic. I opened Inkscape and I made myself a new icon, which although it is not the best in the world, looks better than the original. But how to add it to the extension?

Firefox has some extensions that simply unzip into folders within /home/ /.mozilla/firefox/ .default / extensions /, but there is another that remain as a .xpi as the case of Screengrab.

The first thing I did was unzip the .xpi using Ark el File Manager de KDE, riding a GNOME they can do it with File Roller. Inside the folder that was unzipped, I looked for the icons that I needed to modify, which were in the folder-screengrab / chrome / skin /, and I replaced them with the exact same size, but using my own.

Ready .. and now comes the magic. What we have to do is select all the folders and files that are inside the unzipped folder (not the folder itself), and once they are all selected, we compress them into a .zip. (It has to be .zip)

To the file that was generated, we changed the name and the extension. In my case I put screengrab.xpi

All that remains is to install the extension from the add-ons manager Firefox and voila .. Here is the result 😛

For the record, before modifying any extension, and depending on the use that is going to be given, it is necessary to consult the extensions page of Mozilla or on the author's website the type of license he has, it is not something that we are violating the law.

If you want to know how to create an extension from scratch, with everything you need and more, you can consult this link.


Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: Miguel Ángel Gatón
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.

  1.   gussound said

    What firefox theme do you have installed?

    1.    elav said

      FXChrome ..

  2.   nosferatuxx said

    Great, very good tip.

    1.    elav said

      Thanks .. It is always useful if we want things the way we like 😀

  3.   st0rmt4il said

    Utill ..

    Thank you!

  4.   truko22 said

    Cool 😀

  5.   anti said

    Is the process similar with Chrome and derivatives?

  6.   core123 said

    Very good Tip. It is appreciated ...

  7.   rots87 said

    I suppose that by doing that we would lose the updates from the author

  8.   Stif said

    Excellent tip!

  9.   Federico said

    Very good tip, thanks elav.

  10.   msx said

    So are they just .zip? And so much mystery for that?
    Worse and worse Mozilla.

    Good tip, thanks for sharing.

    1.    v3on said

      what did you expect? subatomic calculations or what? You would be surprised to know how many formats, open and closed, are only containers that have the extension changed and that's it, by the way the chrome extensions too, I haven't worked with the opera extensions but I wouldn't be surprised

      1.    msx said

        Suck me an egg.

        Be careful to get on a horse higher than you can ride, the blow is going to be strong, salami.

  11.   Algave said

    Very good tip to change those ugly icons (I hope I am not breaking the law). 🙂

  12.   Ale said

    Great !! Thank you very much for the post! 🙂