About merging, third part

Thibault North tnorth at bluewin.ch
Mon Jun 20 14:17:32 BST 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,
I think I already sent this to the list, but I never saw it then... so
here it is one more time.

This is a copy/paste of a very simple situation where merging is
required. A directory, 1/, is at home, while 2/ is created to another
computer, using bzr branch.
The user first puts a patch into 2/, then another on the same file
into 1/.
Now, he has two repositories with two different versions of that file.
I think merging 2/ into 1/ should bring a conflict ... but it doesn't :

tnorth at athlon600:/tmp/test$ mkdir 1
tnorth at athlon600:/tmp/test$ cd 1
tnorth at athlon600:/tmp/test/1$ bzr init
tnorth at athlon600:/tmp/test/1$ echo "Foo" > file1
tnorth at athlon600:/tmp/test/1$ echo "Bar" > file2
tnorth at athlon600:/tmp/test/1$ bzr add *
added file1
added file2
tnorth at athlon600:/tmp/test/1$ bzr commit -m "Initial import"
* looking for changes...
added file1
added file2
* commited r1
tnorth at athlon600:/tmp/test/1$ cd ..
tnorth at athlon600:/tmp/test$ bzr branch 1 2
Added 2 texts.
Added 1 inventories.
Added 1 revisions.
0 conflicts encountered.

tnorth at athlon600:/tmp/test$ cd 2/
tnorth at athlon600:/tmp/test/2$ echo "A patch from far away from home"
>> file1
tnorth at athlon600:/tmp/test/2$ bzr commit -m "Patch from somewhere"
* looking for changes...
modified file1
* commited r2
tnorth at athlon600:/tmp/test/2$ cd ../1/
tnorth at athlon600:/tmp/test/1$ echo "Another patch from home" >> file1
tnorth at athlon600:/tmp/test/1$ bzr commit -m "usefull patch from home"
* looking for changes...
modified file1
* commited r2
tnorth at athlon600:/tmp/test/1$ bzr merge ../2/ .
0 conflicts encountered.

tnorth at athlon600:/tmp/test/1$ more *
::::::::::::::
file1
::::::::::::::
Foo
A patch from far away from home
::::::::::::::
file2
::::::::::::::
Bar

What's wrong ?
I really don't understand well these SCM yet !

Regards,
TNorth
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFCtsHr6Xb3bo96D2URAr5IAJ97lye62Bzq8dFPtJJYrQ3KViodBACgiYwK
xJvhSmmoU1M/agTX+Ob54Dc=
=TjNw
-----END PGP SIGNATURE-----





More information about the bazaar mailing list