Search code examples
svnversion-controltortoisesvn

Creating new SVN Repo: E180001: Unable to open repository


We're starting a new Unreal project and it looks like we need to use SVN. Some of us have used it, but none of us have set up the repo before.

I'm loosely following the instructions in this quick start guide: https://subversion.apache.org/quick-start#installing-the-client

The Files

I created the Unreal project from one of the starter templates, and let's say those files are in c:\Game Dev\New Game.

Repo Creation

I'm using TortoiseSVN. Apparently we can't make a non-empty folder into a repo (a weird limitation, but okay), so I created c:\Game Dev\New Game Master. I right clicked the new, empty folder, and used TortoiseSVN -> Create repository here -> Create folder structure -> OK. So far, so good.

File Import

From the command line, I navigated to the original New Game folder where the files are and ran svn import "file:///c:/Game Dev/New Game Master". No error messages, so I'm assuming it worked. svn status gives me svn: warning: W155007: 'C:\Game Dev\New Game Master' is not a working copy, which is expected.

Working Copy

Here's where I'm stuck.

From c:\Game Dev:

svn checkout "file:///C:/Game Dev/New Game Master/trunk" "New Game Local"
svn: E170013: Unable to connect to a repository at URL 'file:///C:/Game%20Dev/New%20Game%20Master'
svn: E180001: Unable to open repository 'file:///C:/Game%20Dev/New%20Game%20Master'

svn status seems to think it IS a repo. What am I missing here?


Solution

  • Subversion is not like git, where everything is on the same directory. Subversion is a centralised version control system and it has very different entities (one repository and zero to infinite working copies), each one on its own location. Your current directory structure is seemingly mixing everything:

    c:\
        Game Dev\ --> Working copy
            New Game --> Unversioned project code
            New Game Master --> Repository
    

    Try separating things and using a more intuitive naming convention:

    C:\
        Game Dev\
            Repository\ ---> Repository
            Template\ ---> Unity template
            Project\ ---> Working copy #1
    

    Also, you didn't install a GUI tool to struggle with commands:

    1. Right click on "Repository" and select "Create repository here". Then click "Create folder structure" and "Start Repobrowser".

    2. Double click on "trunk" and copy the path from the "URL" input.

    3. Right click on "Project" and select "Checkout". Fill the repository URL with your clipboard contents (though I believe it should already be populated) and click "OK". You'll see a green overlay icon on the folder and, when you right click and select "Show log", history should be displayed.

    4. Move/Copy the contents of "Template" into "Project". Right click on "Project" and select "Commit". Verify everything's alright, enter a commit message and click "OK".

    For what it's worth, nobody really stores the repository among project files and working copies. Repository is typically in a different server, and it's accessed through HTTPS.