Hello,

imagine the following repository structure:

/branches/prj1/first.txt
/branches/prj1/second.txt
/branches/prj2/first.txt
/branches/testing/first.txt
/branches/testing/second.txt
/trunk/first.txt

All first.txt in /branches/* are from the same /trunk/first.txt
The file was only changed in /trunk and synced in /branches/prj1/

prj1 was merged into testing

Why is there a tree conflict when I try to merge prj2 into testing? It
is the same file.

Below is a .bat file for creating the repo with some more conflicts that
we do not understand. I would be happy if someone could explain these as
well.


What I try to achieve with the additional testing branch is to have some
kind of staging before going live.

The idea is to do this for new features:
1. Create branch from the latest live system /(trunk)
2. Work on branch
3. Merge branch into testing system (/branches/testing)
4a If everything is ok merge into /trunk and delete branch
4b If something is wrong return to 2.

Best regards
Sven.


@REM testsvn.bat

cls

svn --version
@REM svn, Version 1.7.2 (r1207936)
@pause
svnadmin --version
@REM svnadmin, Version 1.7.2 (r1207936)
@pause
D:
cd \
mkdir test
cd test

svnadmin create repo
svn checkout file:///D:/test/repo wc

cd wc
mkdir branches
mkdir tags
mkdir trunk
svn add branches tags trunk
svn commit -m "basic repo structure"
svn switch --ignore-ancestry file:///D:/test/repo/trunk

svn info
@REM Working Copy Root Path: D:\test\wc
@REM URL: file:///D:/test/repo/trunk
@pause

echo .>first.txt
svn add first.txt
svn commit -m "1st"

svn copy -m "prj0" . "^/branches/prj0"

svn copy -r HEAD -m "prj1" "^/trunk" "^/branches/prj1"
svn switch "^/branches/prj1"
echo .>second.txt
svn add second.txt
svn commit -m "2nd"

svn switch "^/trunk"
svn copy -r HEAD -m "testing" "^/trunk" "^/branches/testing"

echo "change" > first.txt
svn commit -m "change"
svn copy -r HEAD -m "prj2" "^/trunk" "^/branches/prj2"

echo "change2" > first.txt
svn commit -m "change2"
svn copy -m "prj3" . "^/branches/prj3"

svn switch "^/branches/prj2"
svn merge "^/branches/prj1"
svn commit -m "prj1 into prj2"

svn switch "^/branches/prj3"
svn merge "^/branches/prj0"
@REM    C first.txt
@REM --- Recording mergeinfo for merge of r2 through r11 into '.':
@REM  U   .
@pause
svn st
@REM  M      .
@REM       C first.txt
@REM       >   local add, incoming add upon merge
@pause
svn revert -R .

svn switch "^/branches/prj1"
svn merge "^/trunk"
svn commit -m "prj1 sync"

svn switch "^/branches/testing"
svn merge "^/branches/prj1"
svn commit -m "prj1 into testing"

svn merge "^/branches/prj2"
@REM --- Recording mergeinfo for merge of r2 through r7 into '.':
@REM  U   .
@REM -- Zusammenfuehren von r8 bis r13 in '.':
@REM    C second.txt
@REM  G   .
@REM --- Recording mergeinfo for merge of r8 through r13 into '.':
@REM  U   .
@pause
svn st
@REM  M      .
@REM       C second.txt
@REM       >   local add, incoming add upon merge
@pause
svn revert -R .

cd \

Reply via email to