Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 5525:dcbda0c4c3eb
Do not display passwords with pull/push/incoming/outgoing
Passwords specified in the repository URL are now displayed as '***'
when accessing the remote repository.
author | Manuel Holtgrewe <purestorm@ggnore.net> |
---|---|
date | Mon, 05 Nov 2007 20:29:32 +0100 |
parents | e5eedd74e70f |
children | 253736bb0dc9 000ed6873951 |
line wrap: on
line diff
--- a/mercurial/commands.py Fri Nov 09 20:21:35 2007 -0200 +++ b/mercurial/commands.py Mon Nov 05 20:29:32 2007 +0100 @@ -1652,7 +1652,7 @@ cmdutil.setremoteconfig(ui, opts) other = hg.repository(ui, source) - ui.status(_('comparing with %s\n') % source) + ui.status(_('comparing with %s\n') % util.hidepassword(source)) if revs: revs = [other.lookup(rev) for rev in revs] incoming = repo.findincoming(other, heads=revs, force=opts["force"]) @@ -1962,7 +1962,7 @@ revs = [repo.lookup(rev) for rev in revs] other = hg.repository(ui, dest) - ui.status(_('comparing with %s\n') % dest) + ui.status(_('comparing with %s\n') % util.hidepassword(dest)) o = repo.findoutgoing(other, force=opts['force']) if not o: ui.status(_("no changes found\n")) @@ -2095,7 +2095,7 @@ cmdutil.setremoteconfig(ui, opts) other = hg.repository(ui, source) - ui.status(_('pulling from %s\n') % (source)) + ui.status(_('pulling from %s\n') % util.hidepassword(source)) if revs: try: revs = [other.lookup(rev) for rev in revs] @@ -2142,7 +2142,7 @@ cmdutil.setremoteconfig(ui, opts) other = hg.repository(ui, dest) - ui.status('pushing to %s\n' % (dest)) + ui.status('pushing to %s\n' % util.hidepassword(dest)) if revs: revs = [repo.lookup(rev) for rev in revs] r = repo.push(other, opts['force'], revs=revs)