diff options
Diffstat (limited to 'tools/shared.py')
-rw-r--r-- | tools/shared.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/shared.py b/tools/shared.py index 5fdfdfb8..f919bc8c 100644 --- a/tools/shared.py +++ b/tools/shared.py @@ -615,8 +615,7 @@ class Building: if type(passes) == str: passes = [passes] - input = open(filename, 'r').read() - output, err = Popen([NODE_JS, JS_OPTIMIZER] + passes, stdin=PIPE, stdout=PIPE, stderr=PIPE).communicate(input) + output, err = Popen([NODE_JS, JS_OPTIMIZER, filename] + passes, stdin=PIPE, stdout=PIPE, stderr=PIPE).communicate() assert len(output) > 0 and not output.startswith('Assertion failed'), 'Error in js optimizer: ' + err + '\n\n' + output filename += '.jo.js' f = open(filename, 'w') |