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

loss of 'their file' upon non-existent EDITOR

From: Senthil Kumaran S <senthil_at_collab.net>
Date: 2007-07-12 14:25:10 CEST


I would like to validate the following scenario:

When the conflict editor is called during an update and there is no
                                                     default editor
application, then it does not try to merge the working copy with new
incoming change('their file'), i.e the behavior is like 'accept my
version of file' whereas it should have been like 'no-update at all' to
give an opportunity for future updates.

The following script explains this scenario:

$SVNADMIN create /tmp/repos1
$SVN co file:///tmp/repos1 repos1_wc1
cd repos1_wc1
echo "hello" > test.c
$SVN add test.c
$SVN ci -m 'ww'
cd ..
$SVN co file:///tmp/repos1 repos1_wc2
cd repos1_wc1
echo "Hello" > test.c
$SVN ci -m 'ww'
cd ..
cd repos1_wc2
echo "hEllo" > test.c
$SVN up

When we run the above script we get a prompt for conflict resolution in
the interactive mode like the following:

Select: (p)ostpone, (d)iff, (e)dit, (h)elp :

If I give 'e', when my $EDITOR environment variable is not set, it will
fail to open the editor and quits the interactive mode with the
following error:

svn: None of the environment variables SVN_EDITOR, VISUAL or EDITOR is
set, and no 'editor-cmd' run-time configuration option was found

Now when I do a "svn st" inside repos1_wc2 I get the status as:

! .
M test.c

which obviously loses .their file and merges with .mine file. I think
this should not be the exact intended behavior (instead it should leave
the file in the C ie., conflicted state). I tried writing a test case
for this in our python test suite, but could'n do it, because I am
unaware of how to pass the 'e' option to run_and_verify_update method :(

Before I write a test case for this scenario by correcting the
run_and_verify_update() to accept the 'e' option, I would like to
validate this scenario.

Senthil Kumaran S
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Jul 12 14:24:40 2007

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.