# HG changeset patch # User Matt Mackall <mpm@selenic.com> # Date 1393533989 21600 # Thu Feb 27 14:46:29 2014 -0600 # Node ID 5614f8cf0861d95bbe853f636db4bcdab77fe183 # Parent 02d0d3aa42e3c02f326f7e71d8374acf28e20a32 ui: suggest config --edit when no username is set diff --git a/mercurial/ui.py b/mercurial/ui.py --- a/mercurial/ui.py +++ b/mercurial/ui.py @@ -449,7 +449,9 @@ except KeyError: pass if not user: - raise util.Abort(_('no username supplied (see "hg help config")')) + raise util.Abort(_('no username supplied'), + hint=_('use "hg config --edit" ' + ' to set your username')) if "\n" in user: raise util.Abort(_("username %s contains a newline\n") % repr(user)) return user diff --git a/tests/test-install.t b/tests/test-install.t --- a/tests/test-install.t +++ b/tests/test-install.t @@ -16,7 +16,7 @@ checking templates (*mercurial?templates)... (glob) checking commit editor... checking username... - no username supplied (see "hg help config") + no username supplied (specify a username in your configuration file) 1 problems detected, please check your install! [1]