Archive for the ‘SVN’ Category

Eclipse Project Set Editor

January 15, 2013 4 comments

psfeditorAn Eclipse Project Set file (.psf) enables quick export and import of files from a repository like Git, SVN etc. Eclipse currently supports exporting files in a repository as a Project Set file. An editor for an existing PSF file is currently missing. The means updating an existing PSF file (for example, adding a new project, removing an existing project etc.) means editing PSF XML by hand!

The Project Set Editor provides a simple user interface to view and edit PSF files (similar to Manifest Editor or Target Definition Editor). The editor also allows directly importing the artifacts in a PSF file.

You can find the project at Eclipse Labs:

Doors are open for testers and committers.


Tags: , ,

Working offline with SVN (using Git)

August 31, 2010 Leave a comment

Recently, I was faced with a challenge of working offline on a project where the sources were stored in a secured SVN repository. I had no access to this repository from outside the local network. Working on a local copy and committing all the changes together to SVN when I am in the network wasn’t an option for me  (I guess I needn’t detail the dangers of working without versioning systems here). Git was there for my rescue. Here’s how I solved the problem. The approach could also be customized to work with an offline Git repository.

Some definitions used in the article
Source: A development  system within the local network (having access to SVN repository). For example, a Windows PC.
Media: A portable media used to transfer the mirrored repository. For example, a USB stick.
Target: An offline development system not connected to the local network. For example, a Macbook


1. Follow steps as mentioned in blog post Using GIT as frontend to SVN to setup GIT on Source

2. Change path to Media and create a bare Git repository clone of the Source repository (created with the above step)
git clone –bare <source> <destination>

For example,
git clone –bare C:\Git\project_source project_media

3. Change path to Target and create a clone of the Git repository of Media repository
git clone <source> <destination>

For example,
git clone /Volumes/USB/Git/project_media project_target

Managing repository name (optional)

This step adds a new name for repository on Media as “usb”. This makes pushing/pulling changes to Media easier.

1. Change path to repository on Source and add a new remote repository with
git remote add usb Media>

For example,
git remote add usb D:\Git\project_media

2. Change path to repository on Target and rename the remote repository “origin” to “usb”
git remote ren origin usb

Syncing repositories

Moving changes from Source to Target

1. Commit all changes to SVN

2. Change path to the Git repository on Source and do a sync with SVN using
git svn rebase

3. Push the changes to Media
git push usb master

4. Change path to the Git repository on Target and pull the changes from Media
git pull usb master

Moving changes from Target to Source

1. Change path to the Git repository on Target and commit all changes on Target to Git

For example,
git commit . -m “Fixed from home”

2. Push the changes to Media
git push usb master

3. Change path to the Git repository on Source and pull the changes from Media
git pull usb master

4. Commit all changes made back to SVN
git svn dcommit

Make sure that at no point changes are pulled on to Media or changes pushed from Media. It must be always the other way around

Tags: ,

Using GIT as frontend to SVN

August 31, 2010 Leave a comment

Git is a distributed versioning system gaining popularity. It overcomes many limitations of SVN. Due to the lack of good tooling for Git, it may not be ideal to migrate existing SVN repositories to Git as of today (unless you are comfortable using the command line). However, Git offers a feature to use it as a front-end to existing SVN repositories. The article describes how to setup Git to use with a secured SVN on Windows.



  • Set the environment variable GIT_SSH to point to plink.exe.
    For example,
    SET GIT_SSH=c:\Program Files\PuTTY\plink.exe
  • Generate public and private keys using PuTTYgen. Contact your system admin to get more details on this and adding your public key to the server
  • To get the public key of the server, launch PuTTY, connect to SVN server with the settings below and click Yes to accept the sever’s public key. You can safely close the login window that opens up after accepting the key

  • If you already have a private key (for example, openSSH key), use PuTTYgen to import the private key (Conversions > Import) and save it in PuTTY format (File > Save Private Key). If you do not have a key yet you can use PuTTYgen to create a new one.
  • Start Pageant. Pageant will display itself as a small icon in the bottom right of the menu bar displaying a computer with a hat
  • Right click the icon and add the path to your private key
  • Optionally, add Pageant to your Startup menu and modify the Pageant entry to automatically load your private key on startup.
    For example,
    C:\Program Files\PuTTY\pageant.exe “c:\Documents and Settings\username\
  • Create a Git repository with
    git svn clone <SVN repository> –stdlayout -r <revision>
    For example,
    git svn clone svn+ssh://hugo@myserver/project –stdlayout -r1830

    Please note that checking out starting from some revision (for example, 1830 above) is faster.
    Leave out the “–stdlayout” option if the respository doesn’t follow the standard SVN trunk-branches-tags structure.
  • Fetch from SVN all updates including branches (if any)
    git svn fetch

Working with Git

  • Now you could make changes to the files and use Git commands to work with the repository. For the complete list of Git commands refer
  • To push all changes made back to SVN
    git svn dcommit
  • To get updates from SVN
    git svn rebase
  • If  SVN has branches and you if would like to create local Git branches connected to the remote SVN branches, do the following steps
    git checkout -b <SVN branch name>
    For example,
    git checkout -b mybranch-local mybranch
Tags: ,