Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
283 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 Answer

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.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...