Mercurial > hg
comparison mercurial/dispatch.py @ 5664:da72b4d24797
Fix income/pull with bundle and -R (issue 820).
Uses ui.setconfig() to tell bundlerepo where the main repo is. This is
needed for when the --repository option is used.
Adds tests to test-bundle and a new test script
test-mq-pull-from-bundle, which plays out the situation that initially
made me detect this bug
(hg -R .hg/patches pull ../bundle.hg).
author | Peter Arrenbrecht <peter.arrenbrecht@gmail.com> |
---|---|
date | Tue, 18 Dec 2007 14:11:13 -0600 |
parents | e04a65111a80 |
children | 863e237b58fb |
comparison
equal
deleted
inserted
replaced
5663:99fdef2e6793 | 5664:da72b4d24797 |
---|---|
329 repo = None | 329 repo = None |
330 if cmd not in commands.norepo.split(): | 330 if cmd not in commands.norepo.split(): |
331 try: | 331 try: |
332 repo = hg.repository(ui, path=path) | 332 repo = hg.repository(ui, path=path) |
333 ui = repo.ui | 333 ui = repo.ui |
334 ui.setconfig("bundle", "mainreporoot", repo.root) | |
334 if not repo.local(): | 335 if not repo.local(): |
335 raise util.Abort(_("repository '%s' is not local") % path) | 336 raise util.Abort(_("repository '%s' is not local") % path) |
336 except hg.RepoError: | 337 except hg.RepoError: |
337 if cmd not in commands.optionalrepo.split(): | 338 if cmd not in commands.optionalrepo.split(): |
338 if not path: | 339 if not path: |