How to disable a plugin in NanoBlogger in Debian GNU/Linux

To disable a plugin in NanoBlogger version 3.2 one must rename the plugin script,, to modify its extension (by convention into .off).

In the nanoblogger Debian GNU/Linux package, plugins are installed in the/usr/share/nanoblogger/plugins/ directory. In order to enable/disable plugins, it is therefore necessary to rename files in that directory, e.g. for the plugin:

sudo mv /usr/share/nanoblogger/plugins/makepage/ \

The problem with that method is that when the nanoblogger package is updated, file is reinstalled in /usr/share/nanoblogger/plugins/makepage/ along with the file, which re-enables the plugin. To make the renaming permanent accross package updates, one must use Debian’s diversion mechanism:

sudo dpkg-divert --divert /usr/share/nanoblogger/plugins/makepage/ \
    --rename --add /usr/share/nanoblogger/plugins/makepage/

This renames the file into, and in all subsequent updates of the package the new files will also be renamed automatically.

To re-enable the plugin, simply remove the diversion:

sudo dpkg-divert --divert /usr/share/nanoblogger/plugins/makepage/ \
    --rename --remove /usr/share/nanoblogger/plugins/makepage/