summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-09-08 13:09:34 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-09-08 13:09:34 +0100
commit276c3ea5993e600766322d0ef5452fe73908a2f3 (patch)
treea037e038ddd52681a6f9bbe124e0acab30d3c9fb
parent9dbe22f88fae49eac34bdb123f2e1acfc24a6a99 (diff)
Revert "start replacing subprocess.call with subprocess.Popen"
This reverts commit 9dbe22f88fae49eac34bdb123f2e1acfc24a6a99.
-rw-r--r--src/backend/libsisyphus.py42
1 files changed, 12 insertions, 30 deletions
diff --git a/src/backend/libsisyphus.py b/src/backend/libsisyphus.py
index 550f26c..8af5bf7 100644
--- a/src/backend/libsisyphus.py
+++ b/src/backend/libsisyphus.py
@@ -185,51 +185,33 @@ def syncPortageTree():
currentBranch = subprocess.check_output(['git', 'rev-parse', '--abbrev-ref', 'HEAD'])
if currentBranch.decode().strip() is 'master':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/master', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/master', '--quiet'])
elif currentBranch.decode().strip() is 'next':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/next', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/next', '--quiet'])
def syncOverlayTree():
os.chdir(redcoreEbuildDir)
currentBranch = subprocess.check_output(['git', 'rev-parse', '--abbrev-ref', 'HEAD'])
if currentBranch.decode().strip() is 'master':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/master', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/master', '--quiet'])
elif currentBranch.decode().strip() is 'next':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/next', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/next', '--quiet'])
def syncPortageCfg():
os.chdir(portageConfigDir)
currentBranch = subprocess.check_output(['git', 'rev-parse', '--abbrev-ref', 'HEAD'])
if currentBranch.decode().strip() is 'master':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/master', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'master', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/master', '--quiet'])
elif currentBranch.decode().strip() is 'next':
- gitExecStage1 = subprocess.Popen(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'], stdoud=subprocess.PIPE)
- gitExecStage2 = subprocess.Popen(['git', 'reset', '--hard', 'origin/next', '--quiet'], stdout=subprocess.PIPE)
-
- gitExecStage1.wait()
- gitExecStage2.wait()
+ subprocess.call(['git', 'fetch', '--depth=1', 'origin', 'next', '--quiet'])
+ subprocess.call(['git', 'reset', '--hard', 'origin/next', '--quiet'])
def syncPortageMtd():
if os.path.isdir(portageMetadataDir):