diff options
| author | Mike Frysinger <vapier@google.com> | 2020-09-06 14:53:18 -0400 |
|---|---|---|
| committer | Mike Frysinger <vapier@google.com> | 2020-11-18 19:10:57 +0000 |
| commit | 8c1e9cbef161f2ff12dadbacf26affd23876fde9 (patch) | |
| tree | fcfdc404568a2d8dbc9edd9ec99ecdd758f8c424 /subcmds/init.py | |
| parent | a488af5ea5c53dd7cf2c90a751e77cc4ba87b7c3 (diff) | |
| download | git-repo-8c1e9cbef161f2ff12dadbacf26affd23876fde9.tar.gz | |
manifest_xml: refactor manifest parsing from client management
We conflate the manifest & parsing logic with the management of the
repo client checkout in a single class. This makes testing just one
part (the manifest parsing) hard as it requires a full checkout too.
Start splitting the two apart into separate classes to make it easy
to reason about & test.
Change-Id: Iaf897c93db9c724baba6044bfe7a589c024523b2
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/288682
Reviewed-by: Michael Mortensen <mmortensen@google.com>
Tested-by: Mike Frysinger <vapier@google.com>
Diffstat (limited to 'subcmds/init.py')
| -rw-r--r-- | subcmds/init.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/subcmds/init.py b/subcmds/init.py index 5ba0d074..f46babfe 100644 --- a/subcmds/init.py +++ b/subcmds/init.py | |||
| @@ -365,7 +365,7 @@ to update the working directory files. | |||
| 365 | return a | 365 | return a |
| 366 | 366 | ||
| 367 | def _ShouldConfigureUser(self, opt): | 367 | def _ShouldConfigureUser(self, opt): |
| 368 | gc = self.manifest.globalConfig | 368 | gc = self.client.globalConfig |
| 369 | mp = self.manifest.manifestProject | 369 | mp = self.manifest.manifestProject |
| 370 | 370 | ||
| 371 | # If we don't have local settings, get from global. | 371 | # If we don't have local settings, get from global. |
| @@ -414,7 +414,7 @@ to update the working directory files. | |||
| 414 | return False | 414 | return False |
| 415 | 415 | ||
| 416 | def _ConfigureColor(self): | 416 | def _ConfigureColor(self): |
| 417 | gc = self.manifest.globalConfig | 417 | gc = self.client.globalConfig |
| 418 | if self._HasColorSet(gc): | 418 | if self._HasColorSet(gc): |
| 419 | return | 419 | return |
| 420 | 420 | ||
