Mercurial > hg-stable
changeset 818:eef752151556
Actually implement the -f switch for push
author | mpm@selenic.com |
---|---|
date | Mon, 01 Aug 2005 23:34:23 -0800 |
parents | cf1d9a01dd92 |
children | 0932bc2fb2be 7a6acd56cd5a 0fc4b1ab57e3 |
files | mercurial/commands.py |
diffstat | 1 files changed, 6 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/commands.py Mon Aug 01 23:23:51 2005 -0800 +++ b/mercurial/commands.py Mon Aug 01 23:34:23 2005 -0800 @@ -819,13 +819,13 @@ return r -def push(ui, repo, dest="default-push"): +def push(ui, repo, dest="default-push", force=False): """push changes to the specified destination""" dest = ui.expandpath(dest) ui.status('pushing to %s\n' % (dest)) other = hg.repository(ui, dest) - r = repo.push(other) + r = repo.push(other, force) return r def rawcommit(ui, repo, *flist, **rc): @@ -1203,7 +1203,10 @@ (pull, [('u', 'update', None, 'update working directory')], 'hg pull [-u] [SOURCE]'), - "^push": (push, [], 'hg push [DEST]'), + "^push": + (push, + [('f', 'force', None, 'force push')], + 'hg push [DEST]'), "rawcommit": (rawcommit, [('p', 'parent', [], 'parent'),