2 0
Sign in to rate

Addon Reloader (for addon developers)

<10kB. Updated 2017-07-11. Only supports Anki 2.0.x.
The author has shared 5 other item(s).


This addon can reload other single-file addons (under certain conditions). It can help speed up addon development, but should be used with caution, as unexpected results can occur. To qualify, the target addon must contain the function addon_reloader_before() - this is allowed to do nothing. (If updating from Addon Reloader r1, using addon_reloader_teardown() still works, but "before" is preferred.) The function addon_reloader_after() is optional. Selecting "Reload addon..." from the "Tools" menu offers a choice of eligible addons. After reloading an addon from this menu, a new option appears: "Reload ADDON_NAME" (with Ctrl+R shortcut) which reloads the same one again. When an addon is reloaded:Addon Reloader calls addon_reloader_before() before reloading the target - design it to undo anything necessary, considering the above two points. For example, if you simply declared a new function and replaced one of Anki's functions with it, this does not need undoing, as it will be replaced with the new version after the addon is reloaded. However, if you used "wrap" or similar, this needs undoing, as it should not be done twice. If present, Addon Reloader calls addon_reloader_after() after reloading - place anything here which should be executed only after reloading, and not when Anki starts. (Most addons won't need anything here.) Some addons are unsuitable for reloading. Suitable addons may also break after certain changes - restart Anki if this happens. Multi-file addons should instead implement their own reloading, with a minimal amount of code in the primary file (so it won't need modifying often). See my KanjiVocab addon for an example. Please post any questions or feedback to: https://github.com/HelenFoster/AnkiAddonReloader/issues Version: r2 (ea7b318) Tested in Anki 2.0.45 License: AGPLv3+ ( https://www.gnu.org/licenses/agpl.html ) Development repo: https://github.com/HelenFoster/AnkiAddonReloader


As add-ons are programs downloaded from the internet, they are potentially malicious. You should only download add-ons you trust.

This add-on previously supported Anki 2.0. You can download the last version supporting 2.0 here. As Anki 2.0 has been discontinued, no support is available for this version.

All Anki 2.1.x Add-Ons


on 1585405123
Thank you for your work!