Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/ui.py @ 1147:d32b91ebad5d
Merge with TAH.
author | bos@serpentine.internal.keyresearch.com |
---|---|
date | Mon, 29 Aug 2005 10:31:41 -0700 |
parents | ee4f60abad93 |
children | 141951276ba1 |
comparison
equal
deleted
inserted
replaced
1146:9061f79c6c6f | 1147:d32b91ebad5d |
---|---|
76 os.environ.get("EMAIL") or | 76 os.environ.get("EMAIL") or |
77 (os.environ.get("LOGNAME", | 77 (os.environ.get("LOGNAME", |
78 os.environ.get("USERNAME", "unknown")) | 78 os.environ.get("USERNAME", "unknown")) |
79 + '@' + socket.getfqdn())) | 79 + '@' + socket.getfqdn())) |
80 | 80 |
81 def shortuser(self, user): | |
82 """Return a short representation of a user name or email address.""" | |
83 if not self.verbose: | |
84 f = user.find('@') | |
85 if f >= 0: | |
86 user = user[:f] | |
87 f = user.find('<') | |
88 if f >= 0: | |
89 user = user[f+1:] | |
90 return user | |
91 | |
81 def expandpath(self, loc): | 92 def expandpath(self, loc): |
82 paths = {} | 93 paths = {} |
83 for name, path in self.configitems("paths"): | 94 for name, path in self.configitems("paths"): |
84 paths[name] = path | 95 paths[name] = path |
85 | 96 |