holms
holms

Reputation: 9600

How to copy svn trunk to branch without keeping history

I know that there's a bunch of topics already, but I've really got hard times with svn in my situation. I have nested trunk directories all around, something like this:

product_name/trunk/product_module/trunk

this is annoying but this is not my choice, and migration to git will be possible only in 2 month, so I'm confused with dir path all the time.

question is: how can I merge product_name/trunk/product_module/trunk/ to product_name/trunk/product_module/branches/uat without transferring all previous commit messages, so that branch uat would only contain merge-commits messages. I'm actually don't want to deal with revision id's if possible. maybe svn copy can do this job?

EDIT: This is not duplicate, question is about merging branches, not moving repositories. The one who voted for closing obviously haven't worked with svn at all if they can't see difference between merging repos and branches. Different tools, different pattern and action and even scenario. And I want full command with all my quoted paths please.

Upvotes: 1

Views: 1263

Answers (1)

nosid
nosid

Reputation: 50144

I am not sure if I understand your question correctly. However, it sounds like a simple question.

You can merge all unmerged changed from trunk to branch with the following command, executed in the working directory of the branch, and without using rev ids:

svn merge ^/product_name/trunk/product_module/trunk

Subversion can distinguish between merge commits and regular commits. The following command only shows the merge commit:

svn log

If you want to see the merge history, you can use the option -g (same as --use-merge-history):

svn log -g

Upvotes: 1

Related Questions