Show More
@@ -1478,11 +1478,20 b' def clone(ui, source, dest=None, **opts)' | |||
|
1478 | 1478 | |
|
1479 | 1479 | Source patch repository is looked for in <src>/.hg/patches by |
|
1480 | 1480 | default. Use -p <url> to change. |
|
1481 | ||
|
1482 | The patch directory must be a nested mercurial repository, as | |
|
1483 | would be created by qinit -c. | |
|
1481 | 1484 | ''' |
|
1482 | 1485 | cmdutil.setremoteconfig(ui, opts) |
|
1483 | 1486 | if dest is None: |
|
1484 | 1487 | dest = hg.defaultdest(source) |
|
1485 | 1488 | sr = hg.repository(ui, ui.expandpath(source)) |
|
1489 | patchdir = opts['patches'] or (sr.url() + '/.hg/patches') | |
|
1490 | try: | |
|
1491 | pr = hg.repository(ui, patchdir) | |
|
1492 | except hg.RepoError: | |
|
1493 | raise util.Abort(_('versioned patch repository not found' | |
|
1494 | ' (see qinit -c)')) | |
|
1486 | 1495 | qbase, destrev = None, None |
|
1487 | 1496 | if sr.local(): |
|
1488 | 1497 | if sr.mq.applied: |
@@ -368,10 +368,17 b' cd qclonesource' | |||
|
368 | 368 | echo foo > foo |
|
369 | 369 | hg add foo |
|
370 | 370 | hg ci -m 'add foo' |
|
371 |
hg qinit |
|
|
371 | hg qinit | |
|
372 | 372 | hg qnew patch1 |
|
373 | 373 | echo bar >> foo |
|
374 | 374 | hg qrefresh -m 'change foo' |
|
375 | cd .. | |
|
376 | ||
|
377 | # repo with unversioned patch dir | |
|
378 | hg qclone qclonesource failure | |
|
379 | ||
|
380 | cd qclonesource | |
|
381 | hg qinit -c | |
|
375 | 382 | hg qci -m checkpoint |
|
376 | 383 | qlog |
|
377 | 384 | cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now