How to uninstall a configlet in my add-on (, that was installed by my add-on)?
with genericsetup (only xml)
knowing that documentation said that configlet can not be removed that way but documentation is over 1200 days old, talking about: uninstall profile
I registered an uninstall profile in configure.zcml
copied over profiles/default to profiles/uninstall
add remove=”True” to configlet
ran plone instance and activated then deactivated my add-on
It is still in control panel
without genericsetup (only python)
create
1
Extensions
folder in root of your add-on
in that folder create
1
Install.py
create function named
1
uninstall
with first argument
1
portal
and in it write code that calls unregisterConfiglet but this option is deprecated, if it is… there must be another way?
with genericsetup (xml+python)
in Extensions/Install.py
in configure.zcml
in setuphandlers.py
create profiles/default/hud_default_various.txt with some random string inside
create profiles/uninstall/hud_uninstall_various.txt with some random string inside
Generic Setup is the way to go,
it is just a small thing of using Extensions/Install.py to call uninstall profile,
there is probably a good reason why uninstall profile is not called on deactivation of add-on,
I would like to know what is up with that someday…