Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Let's say I create a symbolic link file inside an SVN managed path, commit the path to SVN and later checkout the path.

1) Will the symbolic link file survive?

2) If the symbolic link file is made up of a relative path, will it work "everywhere" a checkout is done?

3) Are there gotchas ?

share|improve this question
up vote 15 down vote accepted

In general, Yes.

However, some clients don't work with symbolic links properly. Subclipse, for the Eclipse IDE, creates directories instead of symlinks.

So it's best to make sure your client is doing it right before getting into development.

share|improve this answer
Since I am a big user of Subclipse, this answer makes more sense for me. – jldupont Sep 29 '09 at 17:58
Actually, Subclipse will create symlinks if you're checking out a working copy on Unix or Linux system--we use this all the time where I work (see John T's response). – bedwyr Oct 1 '09 at 3:13
@bedwyr - I'm using Eclipse w/ subclipse at work - on a unix system (Snow Leopard) - and I get folders. Commandline works, other clients work, just not subclipse. – davethegr8 Oct 1 '09 at 22:38
I can't speak for Subclipse as I'm not a user of it, but from the command line, in at least version 1.6.11, I didn't have to do anything special to make it work. I created a symlink in a directory under version control, then committed it as normal. I a fresh checkout of the project the symlink was available and worked as normal. – Matt Setter Jan 17 '12 at 10:58

From the Subversion Features page:

Symbolic links can be versioned.

Unix users can place symbolic links under version control. The links are recreated in Unix working copies, but not in win32 working copies.

  1. Yes

  2. As long as permissions aren't changed, it should.

  3. Won't work on Windows checkouts.

share|improve this answer
stupid windows! – Felipe Alvarez Aug 12 '10 at 11:33
although ntfs would support the feature ;) only nearly nobody knows it... – user375251 May 31 '12 at 13:32
Windows supports true symlinks through the mklink command, available since Vista – Brad Cupit Jul 22 '14 at 12:48
I am not sure I understood your third point. Or perhaps I misread the question? If the symbolic link was created inside a managed path, I am suppose that SVN would think it is a directory/file, but not a link. So what is the problem with Windows — the symbolic link shouldn't appear in the repository at all! – Hi-Angel Feb 12 '15 at 7:47

Symlinks won't survive on a Windows machine, this can be a problem.
On Windows machines the symlinks take the form of placeholder files*), for example:


link ../www_public/styles.css

*): these files have "svn:special" propery with a value of "*".

I sometimes have to export stuff to a windows machine before I can move/upload the project to it's destination server.

I use a small shell script that does a wonderful job at recreating the actual symlinks from the placeholder files:


grep -lr '^link ' . | while read placeholderfile
  linecount=`wc -l $placeholderfile | cut -c1`
  if [ $linecount -eq 0 ] ; then
    linkfile=`cut -c6- "$placeholderfile"`
    ln -sf "$linkfile" "$placeholderfile"

    echo -e "[\E[32;40mOK\E[37;40m] Replaced $placeholderfile with symlink"
    echo -e "[\E[31;40mWARNING\E[37;40m] $placeholderfile contains newline(s)"
  tput sgr0

This script works on the assumption that all files that start with the string "link " and do not contain newlines are symlinks.

share|improve this answer

From Windows 7 onwards, the OS understands symbolic links; see here for some documentation. The regular SVN clients under Windows do not yet support this, but svn under cygwin does!

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .