Tag Archives: svn

Subversion: Move folder from one repository to another

A branch of a project went into a totally different direction. Therfor I wanted to move that specific folder into a new repository e.g.:


To archive this there are several steps needed. You will need shell access to the server where the repository is located.

  1. Backup the source repository (creating a dump) and filter the specific source folder
  2. Create the new repository and the folder structure
  3. Import the dump file into the new repository
  4. Move the folder to trunk Read more »

Using git to install dokuwiki

Since some months now I use Subversion to update my WordPress installation. A simple “svn switch” to the new tag does the trick, and your WordPress installation is up to date! Since my Dokuwiki installation are getting older and older, I decided doing that with Dokuwiki as well. The source code of Dokuwiki is hosted in a Git repository over at Github. I found nowhere a short instruction how to do that with git, so I thought I write one.

First of all, you need git to install git (always strange to install such software on a server, but who cares :-))

sudo aptitude install git-core

When you already have a Dokuwiki installation, you have to convert it to a git repository. Because git clone doesn’t allow using a non-empty directory, we have to work around this limitation. Warning: Using this method you will loose any changes made to Dokuwiki specific files. Configuration and data should be in their own files so you won’t loose such data.

git clone -b stable -n http://github.com/splitbrain/dokuwiki.git
mv dokuwiki/.git/ .
rmdir dokuwiki
git checkout -f

When you are going to install a new installation, use this command

git clone -b stable http://github.com/splitbrain/dokuwiki.git wiki

For security reasons its recommend to disallow the .git directory for HTTP requests by adding these lines to the .git/.htaccess file. You should also remove install.php.

rm install.php
vi .git/.htaccess
order allow,deny
deny from all

To update your installation, just use the command git pull, which will pull the latest commits from the original Github repository.

git pull