Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
282 views
in Technique[技术] by (71.8m points)

svn - Is there a clean way to move / to /trunk?

I made the mistake of creating a Subversion repository without the usual trunk, branches, and tags directories. That is, the root directory of the project maps to the root directory of the repository. Now I want to create a feature branch, but there's no good place to put it. What I'd like to do is move / to /trunk, preserving its properties and history. Am I out of luck?

question from:https://stackoverflow.com/questions/2753789/is-there-a-clean-way-to-move-to-trunk

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

The clean way to do this is using svnadmin to dump out the whole repository using

svnadmin dump

Then create a new repository with the trunk directory at the root, and reload the dump with

svnadmin load --parent-dir trunk

If you do an svn move then that will mess things up if you ever update back to a revision before the move, since the files will move back to their previous location, which is probably not what you want.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

57.0k users

...