Nested SVN checkouts

We use nested svn checkouts for a couple of our projects. In these cases, the project looks something like this:

project > svnUrl1

folder1 > svnUrl1/folder1

folder2 > svnUrl1/folder2

folder3 > svnUrl2

So folder3 is not a sibling in the repository of folder1 or folder2. Sometimes, it's pointing to another repo entirely, sometimes it just points to a different part of the same repo. As an example of when this comes up, we might work on a plugin for an application, leading to a project structure like this:

project > svnUrl_appRepo

folder > svnUrl_appRepo

plugin > svnUrl_pluginRepo

In this case, we want the project files in place around the plugin for the sake of debugging, etc., and we want to be able to easily switch both the project and the plugin to different branches within their respective repos, depending on what we're doing.

What's the best way to set this up so that PhpStorm handles version-control fucntionality properly? I've tried a few different things:

  1. Make folder3 a soft-link to a checkout elsewhere on my machine.
  2. Move folder1, folder2, and folder3 into a common parent that's not the preject root -- i.e., project > parentFolder > folder[1..3] -- then set VCS mappings for each folder in the project settings
  3. Make folder3 its own checkout.

The exact results vary, but the problem is that PhpStorm doesn't properly recognize that there are two repository URLs being used. For intance, in the commit window, it may not recognize all the changes across both URLs, or it may only let me commit one folder or the other. Sometimes, it shows all the changes as though everything is in one checkout; I'm not quite sure in these cases what will happen if I actually perform the commit.

Ideally, it would reconigze that there are two URLs being used and offer a breakdown in the commit dialog that shows each of the base URLS and eactly which files have changed inside both of them, and then send each change to the appropriate repo.

If I do this:

project > svnUrl_appRepo [svn:ignore property set for 'plugin']

folder > svnUrl_appRepo

plugin > svnUrl_pluginRepo

Everything works exactly as expected while using the svn command line utility. PhpStorm, however, remains confused.

I realize that I could use an external on the parent to pull in the sub, but I'm not keen on the idea of having to edit the property instead of doing a simple switch -- it's more work, it's more error-prone, and it's too easy to accidentally commit the modified external property.

Any suggestions?


  • Subversion server v1.6.11
  • Subversion client v1.7.19
  • PhpStorm v9.0
  • OS X 10.10.3



This question seems related:

Any thoughts or guidance?

Permanently deleted user

You could create necessary folder structure, check out working copies from necessary repositories to subfolders (such subfolders should be unversioned to parent working copy), and not mark these subfolders as ignored - so you'll get working copy with several inner working copies. Corresponding information should be presented in "Subversion Working Copies Information" tab.

During commit, if repositories are different, several underlying "svn commit" commands will be performed. And thus several commits in different repositories will be created. You could check this afterwards in "Repository" tab.


Please sign in to leave a comment.