From 55a0e89c264a89de03112e4b9b41e8e0f49fec0e Mon Sep 17 00:00:00 2001 From: Massimo DiPierro Date: Mon, 12 Mar 2012 13:48:38 -0500 Subject: [PATCH] coffee and less support in response.fields, thanks Sam Sheftel --- VERSION | 2 +- gluon/globals.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 6be3302e..62930809 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 1.99.7 (2012-03-12 12:12:43) dev +Version 1.99.7 (2012-03-12 13:48:35) dev diff --git a/gluon/globals.py b/gluon/globals.py index bf3d7ae8..8d68c947 100644 --- a/gluon/globals.py +++ b/gluon/globals.py @@ -51,6 +51,8 @@ current = threading.local() # thread-local storage for request-scope globals css_template = '' js_template = '' +coffee_template = '' +lass_template = '' css_inline = '' js_inline = '' @@ -252,6 +254,8 @@ class Response(Storage): f = item.lower() if f.endswith('.css'): s += css_template % item elif f.endswith('.js'): s += js_template % item + elif f.endswith('.coffee'): s += coffee_template % item + elif f.endswith('.less'): s += less_template % item elif isinstance(item,(list,tuple)): f = item[0] if f=='css:inline': s += css_inline % item[1]