Most Popular
Recently Added
Recently Updated

Switching to the new Subversion repository hosted by GitHub

Introduction

For many years, we used Subversion for distributing project updates. If you installed Cerb5 from the ZIP download on our website at any point between 4.0 and 5.6 then your installation is probably pointing at our Subversion repository.

In March 2009, we switched the official project to Git and migrated to GitHub to make it even easier to share our source code and collaborate with other developers in the community. GitHub provides services like source code browsing, history, reporting, code reviews, issue tracking, wikis, and more. Despite the benefits of Git and GitHub, this decision also required us to go through several extra steps to keep our Subversion files synchronized with the main project. Not only was that merging process a hassle, but it also created a new place where bugs and other problems could be introduced.

In January 2012 we finally felt confident that the time had come to discontinue our Subversion repository. The major supporting factor in this decision is that GitHub also still provides access to our files through existing Subversion tools.

To continue upgrading your Cerb5 or Cerb6 installation using version control, you will need to make a decision:

  1. We highly recommend that you switch to Git. If you're willing to do this, follow these instructions instead.

  2. Alternatively, you can continue to use Subversion but you will need to switch your installation from pointing to our old Subversion repository to the new one on GitHub. The rest of this article will explain how to do this.

Switching to the new Subversion repository

Normally when a Subversion repository changes hosts you can simply use the svn switch --relocate command and then proceed as usual. However, this requires that the repository history is exactly the same on both hosts up to the point when it moved. GitHub provides access to our files through Subversion, even when we're using Git ourselves, but it does this in a way that is incompatible with our original repository. For this reason, there isn't a simple command you can issue to update your existing Subversion meta information.

Here's what you should do instead:

  1. Make a current backup of your database.

  2. Move your existing cerb6/ directory to somewhere else (for example, cerb6_old/). This directory might be named something else, like support/ or helpdesk/.

  3. Checkout the latest stable project files from GitHub using Subversion:
    svn checkout https://github.com/wgm/cerb6/branches/stable cerb6

  4. Copy or move the contents of your existing cerb6_old/storage/* directory to cerb6/storage/

  5. Manually copy the settings from your existing framework.config.php file to the new one. The most important settings are the ones at the top that start with APP_DB_*. You'll also want to make sure you copy LANG_CHARSET_CODE and DB_CHARSET_CODE so your encoding is set properly. You should not just overwrite the new framework.config.php file with the old one because the format of this file can change between releases.

  6. Delete the cerb6/install/ directory.

  7. Make sure your webserver has recursive write access to the new cerb6/storage/ directory and read access to everything else.

  8. If you had originally installed Cerb in a directory other than cerb6/ (like helpdesk/) then you can move it back.

  9. Visit your helpdesk in a web browser. This should redirect you to the /update page to migrate your database to the new version (if it doesn't you can type in this URL manually).

You should be all set. In the future you only need to run the command svn update in your cerb6 directory to upgrade to the latest stable version.


Properties ID: 000090   Views: 7800   Updated: 2 years ago
Filed under:
knowledgebase comments powered by Disqus