Mercurial > public > mercurial-scm > hg
comparison mercurial/changegroup.py @ 22970:d82e2223f132
prechangegroup: use hook argument from the transaction
There can be useful data in there (eg: bundle2 related one)
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Tue, 14 Oct 2014 00:43:20 -0700 |
parents | 805c18b27f48 |
children | 3fe571c74b27 |
comparison
equal
deleted
inserted
replaced
22969:805c18b27f48 | 22970:d82e2223f132 |
---|---|
601 cl.delayupdate() | 601 cl.delayupdate() |
602 oldheads = cl.heads() | 602 oldheads = cl.heads() |
603 | 603 |
604 tr = repo.transaction("\n".join([srctype, util.hidepassword(url)])) | 604 tr = repo.transaction("\n".join([srctype, util.hidepassword(url)])) |
605 try: | 605 try: |
606 repo.hook('prechangegroup', throw=True, source=srctype, url=url) | 606 repo.hook('prechangegroup', throw=True, source=srctype, url=url, |
607 **tr.hookargs) | |
607 | 608 |
608 trp = weakref.proxy(tr) | 609 trp = weakref.proxy(tr) |
609 # pull off the changeset group | 610 # pull off the changeset group |
610 repo.ui.status(_("adding changesets\n")) | 611 repo.ui.status(_("adding changesets\n")) |
611 clstart = len(cl) | 612 clstart = len(cl) |