Skip to content

Instantly share code, notes, and snippets.

@nebulak
Last active August 20, 2023 21:17
Show Gist options
  • Save nebulak/488d3cb2b29f921e2bbed12e5e8ddd3f to your computer and use it in GitHub Desktop.
Save nebulak/488d3cb2b29f921e2bbed12e5e8ddd3f to your computer and use it in GitHub Desktop.
Outdated: Ressources and useful links for Thunderbird addon development

Ressources for Thunderbird addon development

Most content of this gist is outdated, as the TB addon system has changed and now uses the same addon system, that is used by firefox

Mozilla pages

Collection of useful code snippets and guides

Common

get OS

Returns OS as string e.g. "WINNT".

Complete list at https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/OS_TARGET

function getOS() {
  var { classes: Cc, interfaces: Ci, utils: Cu } = Components;
  var xulRuntime = Cc["@mozilla.org/xre/app-info;1"].getService(Ci.nsIXULRuntime);
  return xulRuntime.OS;
}

Working with files

https://developer.mozilla.org/en-US/docs/Mozilla/JavaScript_code_modules/OSFile.jsm/OS.File_for_workers

Adding a preferences menu

https://developer.mozilla.org/en-US/docs/Adding_preferences_to_an_extension

Accessing Attachments in compose window

https://dxr.mozilla.org/comm-central/source/mail/components/compose/content/MsgComposeCommands.js#4620

Install Addon without user interaction

Online Books

Guides

Simple Addons

@nebulak
Copy link
Author

nebulak commented Aug 20, 2023

Thanks, for your response! I know how frustrating it can be to find outdated pages. I have now tagged it as outdated in the title and content :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment