Dougal Campbell's geek ramblings

WordPress, web development, and world domination.

WordPress Packages?

WordPress On my way to work recently, I was listing to a Drupal podcast (because I had already listened to all of my WordPress-related podcasts). The participants spent some time talking about something they called “Drupal Distributions”. This is a Drupal feature that lets a developer pre-package the Drupal CMS with a set of modules and settings to create a custom install tailored to a specific task.

Each distribution takes some set of Drupal themes and modules and packages them together with the Drupal core, along with custom installation steps, documentation, and so on. For example, one could create a distribution called “Drupal for Education”; it could have pre-configured roles and permissions for both teachers and students, and ship with additional modules that allow one to offer online courses and testing.

They went on to talk about various aspects of this feature, what was good, what still needed improvement, etc. I’m not terribly familiar with the inner-workings of Drupal, but it sounded like this feature is used to good effect, and that they had some really good ideas for how to make it better.

If you are a developer who sets up web sites for clients, then you can probably see how this would be useful. You probably have a favorite set of plugins that you typically install on your client sites. And you probably have to do it from scratch each time, installing and activitating the plugins, then visiting the settings pages and tweaking the default settings to your needs each time. There’s got to be a better way, right?

This reminded me of a tidbit that had come across the wp-hackers mailing list a few weeks ago that I had not been aware of, previously. WordPress has a sorta-kinda similar feature that allows you to customize the initial setup. It requires some time and programming, but it’s probably useful to some of you out there that deploy a lot of sites.

How does it work? Well, did you know that during the install process, WordPress looks for an additional install.php file in the wp-content directory? Neither did I. And did you know that several of the core install functions are ‘pluggable’? You can replace their functionality with your own, by defining them in the custom install.php file.

All the gritty details are in the article Automating WordPress Customizations – the install.php way over at WordPress Bits.

Granted, this still doesn’t make it easy to auto-install a suite of plugins and pre-configure them all. But if you know you’re going to install a bunch of sites that need the same initial setup, it could be worth the time to use this functionality to create a custom install script. You could bundle the core WordPress, a theme, some plugins, and your custom installer. The custom install script could override some of the standard WordPress default settings, set the active theme and plugins, create custom user roles, etc.

If you have the time to listen to the podcast I mentioned at the beginning of the article, you could probably get some ideas on how this could be improved. Imagine if WordPress defined a way to set plugin dependencies, or if there was a set of standard plugin option names that you could depend on for certain things.

Have you ever used this feature? How would you use it, if you had the chance? What improvements can you think of?

About Dougal Campbell

Dougal is a web developer, and a "Developer Emeritus" for the WordPress platform. When he's not coding PHP, Perl, CSS, JavaScript, or whatnot, he spends time with his wife, three children, a dog, and a cat in their Atlanta area home.
This entry was posted in WordPress and tagged , , , , , , , , , , . Bookmark the permalink.

13 Responses to WordPress Packages?

  1. Scott Hildebrand says:

    It’s called an Installation Profile I think… IIRC. There’s some cool stuff but the community is so scatterbrained with parallel stable versions. I guess the speed of development is good, but nothing ever seems solid or complete.

    • Dougal says:

      Yeah, listening to the discussion, I got confused about which of the profile features were already implemented, which were still being developed for the next version, what was in core, and was was provided by add-on modules.

      But some of the ideas were really interesting.

      They also mentioned the fact that (currently) Drupal doesn’t have built-in module updating, and that they are looking at WordPress’ plugin update capability as a source of ideas for how to implement it, handle security concerns, etc.

    • adrian says:

      If you want an example of what an install profile can be , check out http://www.openatrium.com

      And install profiles aren’t that great in d5 / d6 due to implementation issues, but we are working on resolving that.

      • Dougal says:

        Yes, Open Atrium is something they talked about in that podcast, and it had crossed my radar a few weeks ago, when they were preparing to release the beta. I haven’t had a chance to look at it myself, but it sounds very interesting and cool.

  2. Dennis Crane says:

    As a further development of this idea with packages I think you could prepare niche-specific package stuffed with different plugins and offer them to yuor prospects, e.g.:
    - SEO package
    - Graphics\Gallery package
    - Social\Community\Discussion orienter package
    - Context\Banner Ad oriented package
    - Video\Podcast\Music sharing oriented package
    … etc.
    Just turn on your fantasy and market intuition.

    This will help to precisely position your services for different niches and gain more clients.

  3. DD32 says:

    This is actually something i’ve been slowly working towards, An early revision of it is this:
    http://dd32.id.au/2009/07/26/announcing-wordpress-automatic-installer/

    Basically my aim is to allow for plugin “groups” to be automatically installed at the same time as WordPress gets installed..

    Whilst it currently doesnt allow extra Plugin install (And that’ll be the next thing i do once i’ve got a free weekend..), I think its probably a definite thing thats going to happen, Just look at the current generation of “WordPress packages” being sold, You’re not really buying support with many of them, just the fact that the install package has “99 brilliant plugins to improve your blogging experience out of the packet!”….

    • Dougal says:

      I just watched your screencast, and I’m duly impressed!

      Add an easy way to have it fetch other plugins and it’s going to kick some major, major butt. I can definitely imagine this going into Core in the future.

  4. Laura Kalbag says:

    This was something we spoke about at the WordHack lunch at WordCamp UK this year. I love the idea of having something similar to the Add On collections on Firefox.

    From a user/designer point of view, it would be great to have packages that were recommended by developers that really know their stuff!

  5. Otto says:

    Code-wise, automating installation of several plugins is actually pretty easy. A few lines of code to install a plugin from WP-Extend, if you know the slug. Use the plugins_api to get the download link, create a Plugin_Updater class with the right params to install it, call activate_plugin to activate it. A whole lot more lines for user interface and such.

    So it wouldn’t be too difficult to come up with some list of plugins for different cases and then make some code to automate their installation. You could even build it into a plugin, so the user can one-click select a set of plugins for a given task, and have it download them all and activate them in some sequence.

  6. Frank says:

    I think, the actually possibilities to add a own install is easy and very goog. Ise a custom install or write a small plugin to load all options, plugins and settings after the default install. This is a nice way and easy to customize.
    Best regards

    Better and important is the theme of core plugins in the next versions of WordPress.

  7. Maria says:

    I love wordpress is more easy and give me more, a packages is really interesting then we can have a lot of more tools in one. I´m really new in this and i´m learning a lot when i read blogs like this, thaks for the information !

  8. shawn says:

    I sure hope this makes it into wp someday. I run a wpmu network where I find that I spend most of my day simply setting up new sites that for the most part all use the same theme/widgets/plugins.

    Having it automated in wpmu would save me so many hours a month that I could actually contemplate leaving the office from time to time.

  9. Pingback: Six Revisions On Missing Features In WordPress

Leave a Reply

%d bloggers like this: