Mercurial > hgsubversion
comparison svncommand.py @ 297:1611834e39ee
Prevent '.hg/svn/url' from overriding a URL specified on the command line.
author | Dan Villiom Podlaski Christiansen <danchr@gmail.com> |
---|---|
date | Fri, 27 Mar 2009 02:17:33 +0100 |
parents | de3807ceea5c |
children |
comparison
equal
deleted
inserted
replaced
296:9be04de434ed | 297:1611834e39ee |
---|---|
33 if len(candidates) == 1: | 33 if len(candidates) == 1: |
34 subcommand = candidates[0] | 34 subcommand = candidates[0] |
35 path = os.path.dirname(repo.path) | 35 path = os.path.dirname(repo.path) |
36 try: | 36 try: |
37 commandfunc = svn_subcommands[subcommand] | 37 commandfunc = svn_subcommands[subcommand] |
38 if commandfunc not in svn_commands_nourl: | 38 if commandfunc not in svn_commands_nourl and not opts['svn_url']: |
39 opts['svn_url'] = open(os.path.join(repo.path, 'svn', 'url')).read() | 39 opts['svn_url'] = open(os.path.join(repo.path, 'svn', 'url')).read() |
40 return commandfunc(ui, args=args, | 40 return commandfunc(ui, args=args, |
41 hg_repo_path=path, | 41 hg_repo_path=path, |
42 repo=repo, | 42 repo=repo, |
43 **opts) | 43 **opts) |