Merge pull request #2281 from cpennington/fix-i18n-execute
Use subprocess.STDOUT, rather than sys.STDOUT to rebind stderr
This commit is contained in:
@@ -22,7 +22,7 @@ def call(command, working_directory=BASE_DIR):
|
||||
|
||||
"""
|
||||
LOG.info(command)
|
||||
p = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, cwd=working_directory)
|
||||
p = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, cwd=working_directory, shell=True)
|
||||
out, err = p.communicate()
|
||||
return (out, err)
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ def msgfmt_check_po_file(filename):
|
||||
"""
|
||||
# Use relative paths to make output less noisy.
|
||||
rfile = os.path.relpath(filename, LOCALE_DIR)
|
||||
out, err = call(['msgfmt', '-c', rfile], working_directory=LOCALE_DIR)
|
||||
out, err = call('msgfmt -c {}'.format(rfile), working_directory=LOCALE_DIR)
|
||||
if err != '':
|
||||
log.info('\n' + out)
|
||||
log.warn('\n' + err)
|
||||
|
||||
Reference in New Issue
Block a user