Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

svn move project to a different folder

so, i have a project in some path /main/oldProject/ with trunk, and branches folders within. I need to move the trunk and branches folder to a new one called /main/newProject/. I already imported an empty /main/newProject/ folder with TortoiseSVN but i don't know how to move all the contents from the existing folders.

i thought that svn export would do the trick but then i noticed that this will not move uncommitted changes. This is workable for me, but i was hoping there was a way to just copy the folders in the new one and run some operation that will let me work on the new path

any ideas?

like image 605
lurscher Avatar asked Apr 13 '11 15:04

lurscher


People also ask

How do I move files in SVN without losing history?

If you right-drag the folder and use "SVN move versioned item(s) here", then you keep the history. Even the history of the files within the folder. But, the log dialog won't show the history unless you uncheck the box "Stop on copy/rename".

How do I copy a folder from one directory to another in SVN?

The easiest way to copy files and folders from within a working copy is to use the right drag menu. When you right drag a file or folder from one working copy to another, or even within the same folder, a context menu appears when you release the mouse.

How do I move my TortoiseSVN repository?

If you are using TortoiseSVN (and I'm sure there's a command line tool for this as well, but I'm using Tortoise), you can simply right-click on your existing working copy folder and select TortoiseSVN –> Relocate. In the dialog that comes up, enter the new location of the repository, and click OK.

How do I unlink a directory in SVN?

The answer is surprisingly simple - export the folder to itself! TortoiseSVN detects this special case and asks if you want to make the working copy unversioned. If you answer yes the control directories will be removed and you will have a plain, unversioned directory tree.


1 Answers

I take it that this move is within a single repository? If so, checkout the repository to a local working copy somewhere and simply drag the trunk & branches folders in Windows Explorer using the right mouse button instead of the left. When you release, a dialog box will appear and give you the option of an SVN Move or an SVN Copy. Choose whichever is appropriate in your case and commit.

This will perform a proper SVN copy/move with full history.

like image 142
Quick Joe Smith Avatar answered Oct 16 '22 14:10

Quick Joe Smith