make verbose execute and non verbose execute do the same things
This commit is contained in:
parent
435e027dc3
commit
c122852f09
1 changed files with 3 additions and 3 deletions
|
@ -161,11 +161,11 @@ def safe_mkdir(path):
|
||||||
raise
|
raise
|
||||||
|
|
||||||
|
|
||||||
def execute(argv, env=os.environ):
|
def execute(argv, env=os.environ, cwd=None):
|
||||||
if is_verbose_mode():
|
if is_verbose_mode():
|
||||||
print ' '.join(argv)
|
print ' '.join(argv)
|
||||||
try:
|
try:
|
||||||
output = subprocess.check_output(argv, stderr=subprocess.STDOUT, env=env)
|
output = subprocess.check_output(argv, stderr=subprocess.STDOUT, env=env, cwd=cwd)
|
||||||
if is_verbose_mode():
|
if is_verbose_mode():
|
||||||
print output
|
print output
|
||||||
return output
|
return output
|
||||||
|
@ -183,7 +183,7 @@ def execute_stdout(argv, env=os.environ, cwd=None):
|
||||||
print e.output
|
print e.output
|
||||||
raise e
|
raise e
|
||||||
else:
|
else:
|
||||||
execute(argv, env)
|
execute(argv, env, cwd)
|
||||||
|
|
||||||
|
|
||||||
def electron_gyp():
|
def electron_gyp():
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue