changeset 3278:23682d3e4111

disallow commands on non local repository
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Fri, 06 Oct 2006 19:21:43 +0200
parents 105253b30239
children 4b2d3c8a6195
files mercurial/commands.py
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Fri Oct 06 18:38:32 2006 +0200
+++ b/mercurial/commands.py	Fri Oct 06 19:21:43 2006 +0200
@@ -3283,6 +3283,8 @@
 
             path = u.expandpath(options["repository"]) or ""
             repo = path and hg.repository(u, path=path) or None
+            if repo and not repo.local():
+                raise util.Abort(_("repository '%s' is not local") % path)
 
             if options['help']:
                 return help_(u, cmd, options['version'])