[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

merging with and without --force produces different results

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: 2005-12-22 19:05:08 CET


For some days now we've been tracking some strange differences in
merging with TSVN and the CL client which we couldn't really explain.
Now I found the reason. But I'm not quite sure if it's a bug in the
Subversion lib or if that's intended.

Attached is a bat script file (with txt extension to get past ISP virus
checkers) which reproduces this.

Run the batch file. At the end, you'll see a file "file1.cpp" inside

If you now change the last line from
svn merge -r4:5 %REPO%/branch/b %WC%
svn merge -r4:5 %REPO%/branch/b %WC% --force

and run the script again, the "file1.cpp" isn't there anymore after the

I always thought that the --force flag wouldn't change what get's merged
and what doesn't, only that it would enforce a merge in case it would
otherwise fail?

I've just tested this with the CL client compiled from the 1.3.x branch
(updated half an hour ago).

Our discussion on the TSVN list indicates that this also happens with
older clients.

Can someone please check this and explain me if this is really a bug or
if it's intended why (and how) the --force flag changes the behavior of
the merge here?


   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.tigris.org

@echo off
set ROOT=D:/test
set REPONAME=Repos6
set WCNAME=Test6
set REPO=file:///%ROOT%/%REPONAME%

cd %ROOT%
if exist %REPONAME% rd /s /q %REPONAME%
if exist %WCNAME% rd /s /q %WCNAME%
if exist template rd /s /q template

mkdir %REPONAME%
svnadmin create %REPONAME%
mkdir %WCNAME%
mkdir template
cd template
mkdir main
mkdir branch
cd ..
svn import template %REPO% -m r1
rd /s /q template
svn cp %REPO%/main %REPO%/branch/b -m r2
svn co %REPO%/branch/b %WC%
svn mkdir %WC%/folder
echo first > %WC%/folder/file1.cpp
svn add %WC%/folder/file1.cpp
svn ci %WC% -m r3
echo second > %WC%/file2.cpp
svn add %WC%/file2.cpp
svn ci %WC% -m r4
svn mv %WC%/folder/file1.cpp %WC%/file1.cpp
svn ci %WC% -m r5
svn sw %REPO%/main %WC%
echo first merge
svn merge -r2:3 %REPO%/branch/b %WC%
echo second merge
svn merge -r4:5 %REPO%/branch/b %WC%
svn ci %WC% -m r6

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Dec 25 04:35:44 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.