Remove spurious uses of output return values
There are several places in the code where out is collected but not used. These make the code harder to reason about. Remove them and only actually get the output if we care. Change-Id: I0280df56538fc7a56ee2d2bb47f05908270a3045
This commit is contained in:
parent
c28dde9d68
commit
8774e55571
@ -201,11 +201,11 @@ class Mirror(object):
|
|||||||
if short_project.endswith('.git'):
|
if short_project.endswith('.git'):
|
||||||
short_project = short_project[:-4]
|
short_project = short_project[:-4]
|
||||||
if not os.path.isdir(short_project):
|
if not os.path.isdir(short_project):
|
||||||
out = self.run_command("git clone %s %s" %
|
self.run_command(
|
||||||
(project, short_project))
|
"git clone %s %s" % (project, short_project))
|
||||||
self.chdir(os.path.join(project_cache_dir,
|
self.chdir(os.path.join(project_cache_dir,
|
||||||
short_project))
|
short_project))
|
||||||
out = self.run_command("git fetch -p origin")
|
self.run_command("git fetch -p origin")
|
||||||
|
|
||||||
if self.args.branch:
|
if self.args.branch:
|
||||||
branches = [self.args.branch]
|
branches = [self.args.branch]
|
||||||
@ -219,8 +219,8 @@ class Mirror(object):
|
|||||||
print("Fetching pip requires for %s:%s" %
|
print("Fetching pip requires for %s:%s" %
|
||||||
(project, branch))
|
(project, branch))
|
||||||
if not self.args.no_update:
|
if not self.args.no_update:
|
||||||
out = self.run_command("git reset --hard %s" % branch)
|
self.run_command("git reset --hard %s" % branch)
|
||||||
out = self.run_command("git clean -x -f -d -q")
|
self.run_command("git clean -x -f -d -q")
|
||||||
reqlist = []
|
reqlist = []
|
||||||
if os.path.exists('global-requirements.txt'):
|
if os.path.exists('global-requirements.txt'):
|
||||||
reqlist.append('global-requirements.txt')
|
reqlist.append('global-requirements.txt')
|
||||||
@ -232,7 +232,7 @@ class Mirror(object):
|
|||||||
if os.path.exists(requires_file):
|
if os.path.exists(requires_file):
|
||||||
reqlist.append(requires_file)
|
reqlist.append(requires_file)
|
||||||
if reqlist:
|
if reqlist:
|
||||||
out = self.run_command(
|
self.run_command(
|
||||||
venv_format % dict(
|
venv_format % dict(
|
||||||
extra_search_dir=pip_cache_dir, venv_dir=venv))
|
extra_search_dir=pip_cache_dir, venv_dir=venv))
|
||||||
# Need to do these separately. If you attempt to upgrade
|
# Need to do these separately. If you attempt to upgrade
|
||||||
@ -265,7 +265,7 @@ class Mirror(object):
|
|||||||
(reqfp, reqfn) = tempfile.mkstemp()
|
(reqfp, reqfn) = tempfile.mkstemp()
|
||||||
os.write(reqfp, '\n'.join(new_reqs))
|
os.write(reqfp, '\n'.join(new_reqs))
|
||||||
os.close(reqfp)
|
os.close(reqfp)
|
||||||
out = self.run_command(
|
self.run_command(
|
||||||
wheel_file_format % dict(
|
wheel_file_format % dict(
|
||||||
pip=pip, download_cache=pip_cache_dir,
|
pip=pip, download_cache=pip_cache_dir,
|
||||||
find_links=wheelhouse, wheel_dir=wheelhouse,
|
find_links=wheelhouse, wheel_dir=wheelhouse,
|
||||||
@ -291,11 +291,11 @@ class Mirror(object):
|
|||||||
for r in requires:
|
for r in requires:
|
||||||
reqfd.write(r + "\n")
|
reqfd.write(r + "\n")
|
||||||
reqfd.close()
|
reqfd.close()
|
||||||
out = self.run_command(venv_format % dict(
|
self.run_command(venv_format % dict(
|
||||||
extra_search_dir=pip_cache_dir, venv_dir=venv))
|
extra_search_dir=pip_cache_dir, venv_dir=venv))
|
||||||
if os.path.exists(build):
|
if os.path.exists(build):
|
||||||
shutil.rmtree(build)
|
shutil.rmtree(build)
|
||||||
out = self.run_command(
|
self.run_command(
|
||||||
wheel_file_format % dict(
|
wheel_file_format % dict(
|
||||||
pip=pip, download_cache=pip_cache_dir,
|
pip=pip, download_cache=pip_cache_dir,
|
||||||
find_links=wheelhouse, wheel_dir=wheelhouse,
|
find_links=wheelhouse, wheel_dir=wheelhouse,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user