Re: Mercurial - Distributed SCM in Gnome (Was: Git vs SVN (was: Can we improve things?))



Il giorno dom, 23/09/2007 alle 20.31 +0300, Kalle Vahlman ha scritto:
> Sorry, but I did get lost while trying Mercurial just now. I can't
> understand why I need to merge something that I just committed. I
> mean, I just modified a file, committed the change and then tried to
> push the committed change to the place I cloned from. The result was a
> complaint that it would create remote branches and I needed to merge.
> Merge what to where?

You don't need to merge if nothing was changed in the original
repository:

$ # create the original repo and commit a file
$ hg init repo1 && (cd repo1 && echo foo > bar && hg add bar && hg ci -m
'First commit')
$
$ # clone the original repo
$ hg clone repo1 repo2
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
$
$ # do a commit in the cloned repo
$ cd repo2 && echo foobar >> bar && hg ci -m 'Foobar'
$
$ # push the changes to the original repo
$ hg push
pushing to /home/demian/Desktop/repo1
searching for changes
adding changesets
adding manifests
adding file changes
added 1 changesets with 1 changes to 1 files

What did you do to get that message?

-- 
Marco Barisione
http://www.barisione.org/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]