Rocking the blogosphere
Apple Online Store

Editing .xpi files directly in Emacs

One cool feature of Emacs is that it lets you directly edit the contents of various archive files like .zip, .tar, .lzh, .jar, etc. Out of the box, though, Emacs isn’t setup to edit .xpi files automatically, but it’s easy to correct that since .xpi files are just .zip files in disguise and Emacs is eminently customizable…

Just add this to your ~/.emacs file:

(setq auto-mode-alist (cons '("\\.xpi$" . archive-mode) auto-mode-alist))

Ad: Interested in developing Firefox or Thunderbird extensions? Check
out href="http://www.amazon.com/exec/obidos/ASIN/0596000529/marcsepinion-20/103-4418756-8035823?%5Fencoding=UTF8&camp=1789&link%5Fcode=xm2">Creating
Applications with Mozilla from O’Reilly Books. For more Emacs tips, check out Learning GNU Emacs, also from O’Reilly.

Del.icio.us Digg Reddit Technorati

Possibly related posts

Comments

  1. era
    October 12th, 2006 | 11:10 pm

    Shouldn’t this be in the Emacs category, not General?

  2. October 12th, 2006 | 11:56 pm

    Yep, just added it to the Emacs category. Thanks!

Leave a reply

Apple Online Store
Apple Online Store