diff options
Diffstat (limited to 'pavement.py')
-rw-r--r-- | pavement.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pavement.py b/pavement.py index cd52b6f1a..ac9a6fa1a 100644 --- a/pavement.py +++ b/pavement.py @@ -189,12 +189,15 @@ def compile_js(): root = path("module") / "web" / "media" / "js" for f in root.glob("*.coffee"): + print "generate", f coffee = Popen(["coffee", "-cbs"], stdin=open(f, "rb"), stdout=PIPE) yui = Popen(["yuicompressor", "--type", "js"], stdin=coffee.stdout, stdout=PIPE) coffee.stdout.close() content = yui.communicate()[0] with open(root / f.name.replace(".coffee", ".js"), "wb") as js: + js.write("{% autoescape true %}\n") js.write(content) + js.write("\n{% endautoescape %}") @task |