mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
codereview: don't check default paths when codereview disabled
R=golang-dev, rsc CC=golang-dev https://golang.org/cl/5622043
This commit is contained in:
parent
8e765da941
commit
e10150f96d
1 changed files with 5 additions and 5 deletions
|
|
@ -2187,10 +2187,6 @@ def reposetup(ui, repo):
|
||||||
if codereview_init:
|
if codereview_init:
|
||||||
return
|
return
|
||||||
codereview_init = True
|
codereview_init = True
|
||||||
|
|
||||||
remote = ui.config("paths", "default", "")
|
|
||||||
if remote.find("://") < 0:
|
|
||||||
raise hg_util.Abort("codereview: default path '%s' is not a URL" % (remote,))
|
|
||||||
|
|
||||||
# Read repository-specific options from lib/codereview/codereview.cfg or codereview.cfg.
|
# Read repository-specific options from lib/codereview/codereview.cfg or codereview.cfg.
|
||||||
root = ''
|
root = ''
|
||||||
|
|
@ -2200,7 +2196,7 @@ def reposetup(ui, repo):
|
||||||
# Yes, repo might not have root; see issue 959.
|
# Yes, repo might not have root; see issue 959.
|
||||||
codereview_disabled = 'codereview disabled: repository has no root'
|
codereview_disabled = 'codereview disabled: repository has no root'
|
||||||
return
|
return
|
||||||
|
|
||||||
repo_config_path = ''
|
repo_config_path = ''
|
||||||
p1 = root + '/lib/codereview/codereview.cfg'
|
p1 = root + '/lib/codereview/codereview.cfg'
|
||||||
p2 = root + '/codereview.cfg'
|
p2 = root + '/codereview.cfg'
|
||||||
|
|
@ -2220,6 +2216,10 @@ def reposetup(ui, repo):
|
||||||
codereview_disabled = 'codereview disabled: cannot open ' + repo_config_path
|
codereview_disabled = 'codereview disabled: cannot open ' + repo_config_path
|
||||||
return
|
return
|
||||||
|
|
||||||
|
remote = ui.config("paths", "default", "")
|
||||||
|
if remote.find("://") < 0:
|
||||||
|
raise hg_util.Abort("codereview: default path '%s' is not a URL" % (remote,))
|
||||||
|
|
||||||
InstallMatch(ui, repo)
|
InstallMatch(ui, repo)
|
||||||
RietveldSetup(ui, repo)
|
RietveldSetup(ui, repo)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue