Show More
@@ -356,6 +356,9 b' def convert(ui, src, dest=None, revmapfi' | |||
|
356 | 356 | :convert.hg.usebranchnames: preserve branch names. The default is |
|
357 | 357 | True. |
|
358 | 358 | |
|
359 | :convert.hg.sourcename: records the given string as a 'convert_source' extra | |
|
360 | value on each commit made in the target repository. The default is None. | |
|
361 | ||
|
359 | 362 | All Destinations |
|
360 | 363 | ################ |
|
361 | 364 |
@@ -225,6 +225,10 b' class mercurial_sink(converter_sink):' | |||
|
225 | 225 | |
|
226 | 226 | extra = commit.extra.copy() |
|
227 | 227 | |
|
228 | sourcename = self.repo.ui.config('convert', 'hg.sourcename') | |
|
229 | if sourcename: | |
|
230 | extra['convert_source'] = sourcename | |
|
231 | ||
|
228 | 232 | for label in ('source', 'transplant_source', 'rebase_source', |
|
229 | 233 | 'intermediate-source'): |
|
230 | 234 | node = extra.get(label) |
@@ -294,6 +294,10 b'' | |||
|
294 | 294 | branch name for tag revisions, defaults to "default". |
|
295 | 295 | convert.hg.usebranchnames |
|
296 | 296 | preserve branch names. The default is True. |
|
297 | convert.hg.sourcename | |
|
298 | records the given string as a 'convert_source' extra value | |
|
299 | on each commit made in the target repository. The default is | |
|
300 | None. | |
|
297 | 301 | |
|
298 | 302 | All Destinations |
|
299 | 303 | ################ |
@@ -503,3 +507,17 b' test revset converted() lookup' | |||
|
503 | 507 | date: Thu Jan 01 00:00:04 1970 +0000 |
|
504 | 508 | summary: e |
|
505 | 509 | |
|
510 | ||
|
511 | test specifying a sourcename | |
|
512 | $ echo g > a/g | |
|
513 | $ hg -R a ci -d'0 0' -Amg | |
|
514 | adding g | |
|
515 | $ hg --config convert.hg.sourcename=mysource --config convert.hg.saverev=True convert a c | |
|
516 | scanning source... | |
|
517 | sorting... | |
|
518 | converting... | |
|
519 | 0 g | |
|
520 | $ hg -R c log -r tip --template '{extras % "{extra}\n"}' | |
|
521 | branch=default | |
|
522 | convert_revision=a3bc6100aa8ec03e00aaf271f1f50046fb432072 | |
|
523 | convert_source=mysource |
General Comments 0
You need to be logged in to leave comments.
Login now