You are currently browsing articles tagged svn.

If you used Subversion to install Elgg using SSH, upgrading to Elgg 1.1 stable is a snap. Simply log in and:

cd yourelggdirectory

svn sw .

Make sure you include the space and period. Press enter, then agree to accept the security certificate typing t for temporarily or p for permanently. The files will scroll quickly as they are transferred from server to server.

When the transfer is done, open your browser and go to yourelggdirectory.upgrade.php

You should get a message saying the database has been upgraded and land on the login page. Log in and check your version. It should say 1.1 Stable.

Always have a backup of both the files and the database in case something goes wrong. I have done this svn upgrade with the original 1.0 release, and the 1.1 RC1 from the trunk. Note that older themes may exhibit minor quirks.

That’s it. It only takes a minute or two.

More information about Elgg and SVN

Tags: , ,

Just yesterday, the Elgg developers committed Elgg 1.1 RC1. This morning, Elgg 1.1 became an official release–in record time, I’d say. The release is available zipped up at It can also be obtained from their Subversion Repository:

The following posts describe several of the new features in Elgg 1.1

Kudos to the developers for their release offer more features, greater stability and speed. Now we begin the march to Elgg 1.5 in February!

Tags: ,

Since I have been posting about “finds” in Elgg’s Subversion repositories, I have been getting questions about Subversion. Please note that you  don’t need to understand everything covered here to explore and use SVN. Let’s take a look at Subversion and how we can use this incredibly useful tool with Elgg.

Software development projects such as Elgg generally involve several developers working concurrently on the same project. Keeping track of and synchronizing revisions and files could quickly become a nightmare without a central system in place.

This is where Subversion comes into play. Subversion by CollabNet is a widely adopted server based version control system used by Open Source projects as well as the corporate world. Revisions are housed in a server repository. They often can be browsed through a standard web browser, but real access to the files comes through a Subversion client.

Let’s return to Elgg. Elgg actually has separate repositories for extensions and Elgg itself. You can view them in your browser by going to these addresses:

Start by clicking on the the Elgg repository. The first thing that you may notice is a security warning from your browser. You can, in this case, dismiss it. You should see a page that looks like this:

The top of the page shows the revision number. Each time developers commit new files or changes, the revision number goes up. This allows you to keep track of whether or not changes have been made. Below that are links to releases and the trunk. Releases are tested and stable versions of Elgg. Trunk represents the latest code and is not thoroughly tested. Trunk code is very much use at your own risk. It is not recommended for production sites.

If you click on releases, you get an option to select the full or core version of Elgg. Core contains a bare bones install of Elgg; whereas, full contain a set of plugins along with the core.

Note the directory with two periods. That enables you to navigate to the parent folder. Click on full and you have the specific release versions. Currently, there is only version 1.0. Soon you will see 1.1 as well, and as time goes on, subsequent version will appear there.

Returning to the first window code/, we click on trunk and we see another view:

These links are directories and files that contain Elgg code. Click on index.php, for example, and you can view the actual code.

Click to enlarge

Now you have an overview of the repository, but what good is it other than checking progress on code?

That’s where Subversion clients come in. Clients allow you to browse the code, but also have the capability of downloading a directory and all its subdirectories with a single click. It will direct you to specify a folder on your local computer and deliver it all tidily to your hard drive.

Subversion clients come in a number of flavors for all platforms. The most popular version for Window is TortoiseSVN. It is free to download.

Note the browser style address bar to the top of the window. This is where you enter the urls mentioned earlier in this post. It has a Windows Explorer style interface.

To obtain a working copy you need to do a checkout from a repository. Select a directory in the explorer. Right click to pop up the context menu and select TortoiseSVN Checkout. This brings up:

This is where you specify the directory for your checkout (download). In most cases, you would select fully recursive.

Note: I do not have a Windows computer, so I had to get these instructions from the TortoiseSVN support site. I just included this because it is the most frequently used Subversion client. I am unable to offer help beyond what I have written here.

Subversion clients work similarly across packages and platforms. Most people that can run an Elgg site should be able to figure out the nuances of any client. Do a Google search for one suitable for your own computer. I run ZigVersion on my Mac.

From here, you have the code on your hard drive ready to upload via ftp to your server. The main advantage of this is that it gives you access to versions of Elgg that you wouldn’t otherwise.

The real power of Subversion comes into play if you have Subversion installed on your server. If you don’t have it, you should try to get it. You also need ssh access to your server.

In a terminal program, log onto your server. Go to your public_html folder:

cd public_html

Create a directory for your install:

mkdir elgg

Go to your elgg directory:

cd elgg

Give the checkout command (note the space and period following the url–they are important). For the release.

svn co .

For trunk:

svn co .

You will get a warning message:

Click t to accept temporarily or p for permanent and hit return.

Suddenly a scrolling flash of filenames come across your terminal window, transfering elgg to your server in seconds. No time consuming download, unpack, and upload.

If that is not enough to convince you, perhaps the upgrade process will. If you are upgrading the same version of Elgg–as you would with trunk, all you need to do is navigate to your elgg folder in terminal and repeat the command:

svn co .

It will then automatically upload any updated or new files in seconds.

While I have not done this with different versions of elgg releases (as there is only one), in most software you can switch to the new version by navigating to your Elgg directory and type:

svn sw https://whateverthepathistothenewversion/

Again, all will be completed in seconds. You may need to run an upgrade script.

I hope this post is helpful and gets some of you started using Subversion. It is a powerful tool that can open doors in Elgg and many other open source software packages. It is a terrific timesaver as well.

Tags: , ,

Checking into the Elgg SVN repository is something I do on a regular basis. I was surprised to see over 40 revisions since I checked in the other day. Version.php now reflects release number 1.09. We appear to be closing in on the 1.1 release.

Please Note that this is information about upcoming features. As I mentioned in a previous post, working with trunk is risky:

Be warned though, working with the trunk can be risky. The Elgg SVN is currently divided into releases and trunk. The trunk represents the latest code for Elgg, but it is not tested thoroughly like a release is. It is best to work with trunk on test sites. If you do so with a production site, make sure you have backups of both the files and the database!

After uploading the new files and overwriting my installation, I ran upgrade.php to see if there were any revisions to the database between 1.08 and 1.09. Indeed, it did run and upgrade the database. Next, I checked into the admin interface and immediately saw new features.

The first thing I noticed was the ability to change the order in which the plugins load. At the upper left hand corner of each plugin box there are now links to move the plugin up, down, top, or bottom. Developer Ben Wermuller mentioned that this will allow greater customization. I also wonder if it will help resolve issues with plugins not playing well with each other as it does in some cases with Joomla.

The next thing I noticed was a new plugin called Activity:

This plugin gives you the option of replacing the widget propelled dashboard with the activity stream from the River. Enabled, you dashboard displays a list of the latest activities with the standard owner’s block.

You have options to view Site Activity, Your Activity, or Friends’ Activity. It also places an activity option in the toolbar’s dropdown menu.

I look forward to my next trip to the repository as it often results in pleasant surprises.

Tags: , ,

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!

Tags: , , , , , ,