changeset 6234:a47462264906

Hide URL passwords in hg paths output.
author Brendan Cully <brendan@kublai.com>
date Tue, 11 Mar 2008 16:28:58 -0700
parents 14a4fdf9037f
children d16798000be0
files mercurial/commands.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Tue Mar 11 16:04:25 2008 -0700
+++ b/mercurial/commands.py	Tue Mar 11 16:28:58 2008 -0700
@@ -1954,13 +1954,13 @@
     if search:
         for name, path in ui.configitems("paths"):
             if name == search:
-                ui.write("%s\n" % path)
+                ui.write("%s\n" % util.hidepassword(path))
                 return
         ui.warn(_("not found!\n"))
         return 1
     else:
         for name, path in ui.configitems("paths"):
-            ui.write("%s = %s\n" % (name, path))
+            ui.write("%s = %s\n" % (name, util.hidepassword(path)))
 
 def postincoming(ui, repo, modheads, optupdate, checkout):
     if modheads == 0: