I am a complete newb to Subversion, but am trying to get past the frightening shadow of SourceSafe. So I'm learning, trying to teach myself what's what, and I've come across some roadblocks I don't quite understand yet.
SVN 1.7.3 is up and running on a local Linux box. AnkhSVN is installed within my VS 2010 setup. VS/AnkhSVN can talk to my repository. So I started experimenting with some very simple Console projects to get started. I created the trunk, branches, and tags directories as suggested in the guidance I've found so far.
I created a new Console solution, and allowed Ankh to create that project in my repository under the recommended "trunk" folder. After adding nothing more than a "Hello, World" line to Program.cs, I commit the changes to trunk. That works...so far, so good...
I'm now wanting to pretend I'm working on a private branch, so I select Subversion->Branch Project... from "trunk" and the "Head/Latest" version, checking "Switch to Branch after creation." That seems to go well.
Problem 1.
Now here's where things get dicey. I decide to add a single source file to the project in my private branch, adding the file, but I cannot get the file to move from my private branch to trunk. Merging/reintegrate doesn't work. Update doesn't work. Switch doesn't work. Now, after trying a switch from the branch to the trunk, VS tells me my project file is corrupt and can't be loaded.
Obviously, I've done something terribly wrong, but I don't know what. It appears I just need to get a trunk working copy, then do a merge, but how do I do that in my VS project folder setup?
Problem 2
My next problem, or question, which may be part of Problem 1, is understanding how Subversion-managed projects should be structured on the Visual Studio side. Its much clearer to me on the Unix side that you can pull a project into a local folder, but its not at all clear how the typical directory structure of a VS project is supposed to be affected by Subversion. Should the trunk and branches folders be duplicated on the local Visual Studio box as well? If I "switch" from trunk to a private branch (or vice-versa), is the intent that the corresponding files should be going into the same set of VS folders, or should there be a corresponding set for the branches and for the trunk?
Problem 3 This is more of a newbie SVN question, but when SVN tells me there are conflicts, I don't yet understand how to resolve them. Does the ankhSVN plug-in have special tools to resolve conflicts, or do I need to fix them on the host server with the full svn tool? If so, what's is the "most typical" kind of conflict to resolve?
Did you add and commit the file?
You could use switch to the keep same folder, as given in the example here or you could have two separated folders for your trunk and branch. It's up to you and what works for your project. It may be better to use switch if your project has to be in a certain path to work, for example a Web service.
Unfortunately I don't have Ankh in front of me, but you should be able to edit or resolve conflicts with a tool built into Ankh, but you could change the configuration to use a 3rd party tool as well. Documentation here.