Update Manager for ClassicPress

In many cases, ClassicPress users are continuing to find and use plugins available in the WordPress plugin repository. It's convenient. It's easy. The internal plugin updater works without a hassle. However, for some developers – those who are going all-in with ClassicPress – we aren't uploading our new plugins into the WordPress ecosystem. This means we don't get the benefit of the internal plugin updater – we have to work out this functionality on our own. The same problem exists for those who build sites for clients; updating a Utility Plugin is often done manually via FTP, one site at a time.

Remote Updates for ClassicPress Plugins

ClassicPress already has all the functionality in place to serve up plugin updates. Thing is: there's no simple way to say, "...this plugin's updated files are on GitHub and here's the images and info to use..." Well, actually, that's not entirely true: the process is simple once you work it out. But, I digress...

No Extra Plugins to Install

Once you have the Update Manager plugin installed, you'll then include a single file in any plugins you want to update remotely. Your end users won't have to install an extra plugin just to update your plugin. This is the main shortcoming with the GitHub Updater plugin, however, it does offer theme update support which is something the Update Manager plugin doesn't do.

Complete Integration

The f(x) Updater plugin is another decent option. It doesn't require your users to install an extra plugin, but, it does fall a bit short by not providing enough data to fully populate the update screens and dialogs – it actually works, but, things tend to look a little broken. Like the previously mentioned plugin, this one also offers support for updating themes. While it doesn't yet have theme support, the Update Manager plugin solves the remainder of these problems handily, making your end users' experience perfectly native and seamless.

No Difficult Configuration

There are no configuration settings for the Update Manager plugin. Simply create a new update endpoint just like any ClassicPress post and then fill in some values in a text editor. If you have ever edited a plugin's readme.txt file – and, as a plugin author, I know you have – you will be be a pro at this in no time.

Beautiful Output

You know those popup dialogs that appear when you click to learn more about a plugin or an available update? Your header image is going to look great sitting at the top of your listing. And, with full markdwn support, you can really get tricky with displaying your data in all those glorious tabs! What's more, it's possible to pull in screenshots and even add your own plugin reviews and additional notes!

Coming soon!

This page has been put in place to allow for some documentation and supporting materials to be created alongside development of the code. Please do check back!

Frequently Asked Questions

  1. How does the Update Manager plugin work?
    The Update Manager plugin works as a server and a client. That is, one part of the plugin can provide data (the server) while the other part of the plugin can consume that data (the client). As you probably guessed, the Update Manager plugin is the primary server. In your own plugins, you will include a single file along with the rest of your code – this file is the client! When your users check for updates in their dashboard, the client then contacts the server to see if any updates are available. If an update is available, the server lets the client know and an update is made available in the users dashboard.

  2. Is this plugin ready for production?
    I’m releasing this ahead of production to get some extra help with user testing. It is intended for testing purposes on non-production sites at this time.

  3. Where can I serve updates from?
    The Update Manager plugin will be installed on your ClassicPress site, however, you are free to host your files wherever you like. Serve them from GitHub, serve them from your own ClassicPress Media Library, server them from somewhere in the cloud. The Update Manager gives you a single point to control all your plugin and update details.

  4. Can I push updates out for my ClassicPress themes?
    No. The Update Manager plugin only handles the update process for plugins at this time.

  5. Can Update Manager update plugins on the same site where it is installed?
    Yes.

  6. Can Update Manager update itself?
    Yes. Check in the /classes/ directory, you’ll find the very same updater class that you add to your own plugins – the difference is that the server is set to poll my installation of the Update Manager plugin – and if I bump my versions, you’ll get a notice that there’s an update. An update manager plugin that can manage to update itself – it doesn’t get any more meta than that.

  7. Can the Update Manager plugin force automatic updates on end users?
    No. The Update Manager server and client are built to communicate back and forth about the details of plugin versions. You can push an update which will then show up in the user’s dashboard, however, it is up to the user to actually apply the update (or not.)

  8. Will my users have to install anything more than my plugin?
    No. Your end users will only have to install your plugin. In that plugin, you will have included a single extra file to handle communicating back and forth to the Update Manager which is installed on your site. The file will add about 15k to your plugin, so, virtually nothing.

  9. Help! I updated a plugin and it still shows an update is available!
    This will occur if you forgot to bump the version number in your plugin’s primary PHP file to match the new version you specified in the Update Manager. To resolve the issue, be sure to set the version in your plugin’s primary PHP file to match the new version you have specified in the Update Manager before zipping it up and making it available.

  10. How much weight will this add to my plugins?
    If you include the updater file as-is, it will add 10k to your plugin. If you remove the code comments, you can get it down under 5k. It’s tiny. Additionally, the updater allows you to include your own header image and icons to be used in the various displays when users go to update your plugin. These are optional.

  11. Why is this plugin better than other updaters?
    First, your plugin users aren’t stuck installing an extra plugin just to handle updates. The plugin focuses on one task (updating plugins) and does it well. It’s tightly integrated with the ClassicPress update process. Every line of code is commented and it’s completely namespaced, object-oriented code to ensure maximum encapsulation.

  12. What data is sent and received with this plugin? Is it stored or used?
    When your end users check their dashboards for updates, the update client gathers and posts data back to your Update Manager installation. For example, it gathers the values from your user’s installed plugin headers – that is, the commented sections at the beginning of the files, which includes all the basic details of a plugin. The client file also determines the image directory of the particular plugin being updated and the URLs of any discovered banner and icon images related to the plugin. Once this data is gathered, it is sent to the Update Manager plugin where the data is evaluated against the latest versions. If the user is on the latest version, the Update Manager plugin responds with an empty array. If the user is on an old version, the Update Manager responds with an array of properties about the new release – when the client receives this data back, it knows there’s an update ready and makes it available in the dashboard. The received data is used for nothing more than comparing between versions. While no data is stored by the Update Manager plugin or the client file, servers will still likely be capturing certain data, such as the users User Agent, OS, IP address, etc.

Share Your Experience

Had a great experience with the Update Manager plugin for ClassicPress? Share your thoughts and get a link back to your site! Emails are not shared or published.

Related Plugins