MyBB Community Forums

Full Version: Best way to update plugins?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
PluginLibrary handles settings/templates creation/update/removal for you if you like.
The only problem with the current DB caching system is that on every MyBB instance the entire datacache table is queried. If every plugin caches everything, even what's not necessary to cache, you may have some problems.
I now use PluginLibrary to handle all of my settings/templates/cache and it seems to me likethe best practice if you don't want to write your own library or repeat code in every plugin.
(2013-02-06, 06:05 PM)frostschutz Wrote: [ -> ]PluginLibrary handles settings/templates creation/update/removal for you if you like.

Ooooo looks like a pretty useful library. It looks like it does what I'm currently doing, just x10 more advanced.
(2013-02-07, 03:12 AM)Jazza Wrote: [ -> ]
(2013-02-06, 06:05 PM)frostschutz Wrote: [ -> ]PluginLibrary handles settings/templates creation/update/removal for you if you like.

Ooooo looks like a pretty useful library. It looks like it does what I'm currently doing, just x10 more advanced.

well you still need the upgrade script you wrote, its just that you can simplify the specific actions of your code by using the pluginlibrary functions.
I can testify to pavemen's script. I am using it in ASB 1.3.4 and up and it really is a simple way for a plugin to make sure everything is up-to-date upon activation.

What you're doing here is pretty cool too, although I am afraid I don't understand how you will avoid leaving trash behind.

For example, sometimes plugins drop templates or settings altogether . . . how could you possibly prepare for that?
Pages: 1 2 3