One problem with administering multiple programs on several websites is keeping all the software up to date. Sometimes there seems to be an endless string of security updates and it can add up to quite a chore. It is easy to fall behind and leave scripts outdated and vulnerable. This site is a case in point.
I decided to finally get around to updating my WordPress installations. I was getting ready to go through the process of downloading the new version, unpacking it and uploading the files to the server as the instructions dictate. While looking through the WordPress Site, I ran into “Installing/Updating WordPress with Subversion.” This has totally changed how I manage websites.
Let’s start with some background information. SSH is an abbreviation for Secure Shell. It is a way to access a server using a command line interface through a terminal. If you have a Mac or Linux box, you already have this installed. If you have Windows you can download a terminal such as PuTTY or some other such software.
In order to use SSH, you need an account with a webhost that allows SSH access (I would definitely make that a consideration when selecting a host), or a server allowing such access. You launch the terminal and type (don’t type the $–that just indicates a new command):
$ ssh username@ipaddress
If all goes well, you will be prompted to type in a password and you are in your root folder. From that point you can navigate to folders and execute functions using simple commands.
Subversion is a revision management system that many open source communities use to manage different versions of a particular software package. In order to use subversion, a client must be installed on the servering hosting your site (again, if I were looking for a webhost, I’d want that feature).
Once all the requirements are in place, installing software is a cinch. Log into the server as shown above. Navigate to your public_html folder:
$ cd public_html
Create a new folder:
$ mkdir newsoftwarefolder
Go to that folder:
$ cd newsoftwarefolder
Install from subversion server:
$ svn co http://whateverthepathistotheversion/ . (you need the space period and the trailing slash)
You many be prompted to log in–if so login as anonymous with password. That’s it. Instead of downloading, extracting and uploading, you just transferred the files saving much time and effort. Proceed with the rest of the install (ie set up the database and run the browser installer). You can have a site up and running in less than 5 minutes.
The best part come next–future upgrades. If you want the new files of the same version, just navigate to the directory and type:
$ svn up
It then will upload any change files. If you want to upgrade to a newer version just navigate to the directory and type:
$svn sw http://whateverthepathistothenewversion/
Again, it will only update change files leaving your custom files, themes, and plugins alone.
The article linked at the top also outlines how to change an existing installation to a subversion installation. I have applied the same idea to software other than WordPress with great success.
Now this is not for the total novice, but if you are already upgrading software manually, as opposed to using a cpanel to do so, you are probably proficient enough to do this. You’ll save a lot of time and effort, freeing you to concentrate more on teaching!


Recent Comments