Skip to content
Snippets Groups Projects
Unverified Commit ef1f899b authored by John Kessenich's avatar John Kessenich Committed by GitHub
Browse files

Merge pull request #1413 from karl-lunarg/fix-update

script: Improve update sources script
parents 16cf5a5d fa403b96
No related branches found
No related tags found
No related merge requests found
......@@ -66,7 +66,7 @@ def command_retval(cmd, directory):
p = subprocess.Popen(cmd,
cwd=directory,
stdout=subprocess.PIPE)
(stdout, _) = p.communicate()
p.communicate()
return p.returncode
......@@ -95,8 +95,8 @@ class GoodCommit(object):
def AddRemote(self):
"""Add the remote 'known-good' if it does not exist."""
print('Ignore "fatal" errors for missing known-good remote:')
if command_retval(['git', 'remote', 'show', 'known-good'], self.subdir) != 0:
remotes = command_output(['git', 'remote'], self.subdir).splitlines()
if 'known-good' not in remotes:
command_output(['git', 'remote', 'add', 'known-good', self.GetUrl()], self.subdir)
def HasCommit(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment