Mercurial > hgsubversion
diff hgsubversion/wrappers.py @ 783:7913a82a8cdd
Check mercurial/third-parties push conditions before pushing
This prevents pushing MQ applied patches without --force.
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Tue, 01 Feb 2011 00:25:59 +0100 |
parents | d38226a190ad |
children | 4bbc6bf947f5 |
line wrap: on
line diff
--- a/hgsubversion/wrappers.py +++ b/hgsubversion/wrappers.py @@ -123,6 +123,9 @@ def push(repo, dest, force, revs): """ assert not revs, 'designated revisions for push remains unimplemented.' cmdutil.bail_if_changed(repo) + checkpush = getattr(repo, 'checkpush', None) + if checkpush: + checkpush(force, revs) ui = repo.ui old_encoding = util.swap_out_encoding() # TODO: implement --rev/#rev support