Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(99)

Unified Diff: gclient.py

Issue 115322: Remove two seams options.gclient and options.scm_wrapper in gclient. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools/
Patch Set: Created 11 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/gclient_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gclient.py
===================================================================
--- gclient.py (revision 15990)
+++ gclient.py (working copy)
@@ -970,7 +970,7 @@
if not next[1]:
return None
path = next[0]
- client = options.gclient(path, options)
+ client = GClient(path, options)
client._LoadConfig()
return client
@@ -1168,8 +1168,7 @@
raise Error(
"relative DEPS entry \"%s\" must begin with a slash" % d)
# Create a scm just to query the full url.
- scm = self._options.scm_wrapper(solution["url"], self._root_dir,
- None)
+ scm = SCMWrapper(solution["url"], self._root_dir, None)
url = scm.FullUrlForRelativeUrl(url)
if d in deps and deps[d] != url:
raise Error(
@@ -1280,7 +1279,7 @@
entries[name] = url
if run_scm:
self._options.revision = revision_overrides.get(name)
- scm = self._options.scm_wrapper(url, self._root_dir, name)
+ scm = SCMWrapper(url, self._root_dir, name)
scm.RunCommand(command, self._options, args, file_list)
self._options.revision = None
try:
@@ -1305,7 +1304,7 @@
entries[d] = url
if run_scm:
self._options.revision = revision_overrides.get(d)
- scm = self._options.scm_wrapper(url, self._root_dir, d)
+ scm = SCMWrapper(url, self._root_dir, d)
scm.RunCommand(command, self._options, args, file_list)
self._options.revision = None
@@ -1322,7 +1321,7 @@
entries[d] = url
if run_scm:
self._options.revision = revision_overrides.get(d)
- scm = self._options.scm_wrapper(url, self._root_dir, d)
+ scm = SCMWrapper(url, self._root_dir, d)
scm.RunCommand(command, self._options, args, file_list)
self._options.revision = None
@@ -1464,7 +1463,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
if options.verbose:
@@ -1491,7 +1490,7 @@
if os.path.exists(options.config_filename):
raise Error("%s file already exists in the current directory" %
options.config_filename)
- client = options.gclient('.', options)
+ client = GClient('.', options)
if options.spec:
client.SetConfig(options.spec)
else:
@@ -1524,7 +1523,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
if options.verbose:
@@ -1541,7 +1540,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
@@ -1579,7 +1578,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
if options.verbose:
@@ -1596,7 +1595,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
return client.RunOnDeps('revert', args)
@@ -1608,7 +1607,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
if options.verbose:
@@ -1624,7 +1623,7 @@
Raises:
Error: if client isn't configured properly.
"""
- client = options.gclient.LoadCurrentConfig(options)
+ client = GClient.LoadCurrentConfig(options)
if not client:
raise Error("client not configured; see 'gclient config'")
client.PrintRevInfo()
@@ -1713,8 +1712,6 @@
options.entries_filename = ".gclient_entries"
options.deps_file = "DEPS"
- options.gclient = GClient
- options.scm_wrapper = SCMWrapper
options.platform = sys.platform
return DispatchCommand(command, options, args)
« no previous file with comments | « no previous file | tests/gclient_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698