Upgrading WordPress using SubVersion

I have just upgraded my WordPress install to the lastest release, luckily with SubVersion the whole process can be achieved with minimum time and effort.

Paul went through the upgrade steps on his blog, but thought I would go through them here as I went along.

Unfortunately when I initially installed WordPress I committed it directly to the root directory unlike the more popular location of the subdirectory /blog, but not to worry.

Here are the steps I followed to complete the update:

# Backup the current directory...
cp -Rp http httpBACKUP
# Create a new location for the update...
mkdir httpNEW
# Checkout the latest release from the repository...
svn co http://svn.automattic.com/wordpress/tags/2.5/ httpNEW/
# Copy across any custom changes/themes and config file...
cp -Rp http/wp-con* httpNEW/
# Copy over the .htaccess file..
cp -Rp http/.htaccess httpNEW/
# Delete the old directory...
rm -rf http
# Rename/move the update to the original location...
mv httpNEW/ http
# Switch the SubVersion Repository...
svn switch http://svn.automattic.com/wordpress/tags/2.5/
# Finally, run the browser based update script...
http://yourdomain/wp-admin/upgrade.php

And that’s all there is to it really, now every time I need to update WordPress I can simply copy and paste the above commands.

6 Replies to “Upgrading WordPress using SubVersion”

  1. Go Steve!

    How are you finding version 2.5? I haven’t taken the plunge yet as last time I upgraded to the beta version of it, it was lacking image upload support. I think they have fixed this now? Does everything else seem to be working fine for you?

    Paul

  2. Thinking about it, I would only bother doing the last 2 steps next time you upgrade:

    # Switch the SubVersion Repository…
    svn switch http://svn.automattic.com/wordpress/tags/2.5/
    # Finally, run the browser based update script…
    http://yourdomain/wp-admin/upgrade.php

    Since you are using subversion, if things go wrong you can always roll the web scripts back to an older version with another svn switch statement. If anything, I would backup the database rather than the webscripts (as this can’t be rolled back with svn).

  3. You speak the truth in terms of subversion, unfortunately I’m not so familiar with the reverting side of things (yet!) so opted for the easy way out on this one.

    Maybe by the next release I’ll be a little more confident with reverting and do things as suggested – as if it wasn’t easy enough already!

    With regards to image uploads I have just tried uploading a test image and don’t appear to be having any issues, the other features all seem to be working fine also from what I have played with.

  4. As requested I’ve enabled gravatars in the admin panel and edited the theme to include the images next to each post, now your face seems to be everywhere!

Leave a Reply