Mercurial > hg
changeset 3079:4c9fcb5e3b82
If local repository is missing, make error message clearer.
Faheem Mitha suggested finding a better error message.
The nice error message is taken from cogito.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Mon, 11 Sep 2006 10:08:30 +0200 |
parents | baa3873eb387 |
children | e270cbd4aa20 |
files | mercurial/commands.py mercurial/hgweb/server.py mercurial/localrepo.py |
diffstat | 3 files changed, 8 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/commands.py Sun Sep 10 19:15:08 2006 -0300 +++ b/mercurial/commands.py Mon Sep 11 10:08:30 2006 +0200 @@ -2458,7 +2458,8 @@ if opts["stdio"]: if repo is None: - raise hg.RepoError(_('no repo found')) + raise hg.RepoError(_("There is no Mercurial repository here" + " (.hg not found)")) s = sshserver.sshserver(ui, repo) s.serve_forever() @@ -2469,7 +2470,8 @@ ui.setconfig("web", o, opts[o]) if repo is None and not ui.config("web", "webdir_conf"): - raise hg.RepoError(_('no repo found')) + raise hg.RepoError(_("There is no Mercurial repository here" + " (.hg not found)")) if opts['daemon'] and not opts['daemon_pipefds']: rfd, wfd = os.pipe()
--- a/mercurial/hgweb/server.py Sun Sep 10 19:15:08 2006 -0300 +++ b/mercurial/hgweb/server.py Mon Sep 11 10:08:30 2006 +0200 @@ -207,7 +207,8 @@ hgwebobj = self.repoviewmaker(repo.__class__(repo.ui, repo.origroot)) else: - raise hg.RepoError(_('no repo found')) + raise hg.RepoError(_("There is no Mercurial repository here" + " (.hg not found)")) return hgwebobj class IPv6HTTPServer(MercurialHTTPServer):
--- a/mercurial/localrepo.py Sun Sep 10 19:15:08 2006 -0300 +++ b/mercurial/localrepo.py Mon Sep 11 10:08:30 2006 +0200 @@ -27,7 +27,8 @@ oldp = p p = os.path.dirname(p) if p == oldp: - raise repo.RepoError(_("no repo found")) + raise repo.RepoError(_("There is no Mercurial repository" + " here (.hg not found)")) path = p self.path = os.path.join(path, ".hg")