This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project gfxprim.git.
The branch, master has been updated via 870edf9002091a710e94dd929c2e9583af590f34 (commit) from 30d9e3ba8aa2412e028bb51b34d3be44ddf7a92b (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- http://repo.or.cz/w/gfxprim.git/commit/870edf9002091a710e94dd929c2e9583af590...
commit 870edf9002091a710e94dd929c2e9583af590f34 Author: Cyril Hrubis metan@ucw.cz Date: Fri Jan 6 20:27:13 2012 +0100
pylib: Propagate math python buildins to templates
Now we can use int() float() and round() in templates too.
diff --git a/pylib/gfxprim/render_utils.py b/pylib/gfxprim/render_utils.py index d99aa3d..b115b91 100644 --- a/pylib/gfxprim/render_utils.py +++ b/pylib/gfxprim/render_utils.py @@ -28,6 +28,10 @@ def create_environment(config, template_dir): env.globals['len'] = len env.globals['error'] = template_error env.globals['hex'] = lambda(x): hex(x).rstrip('L') + # Propagate some python buildins + env.globals['int'] = int; + env.globals['float'] = float; + env.globals['round'] = round; return env
-----------------------------------------------------------------------
Summary of changes: pylib/gfxprim/render_utils.py | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
repo.or.cz automatic notification. Contact project admin jiri.bluebear.dluhos@gmail.com if you want to unsubscribe, or site admin admin@repo.or.cz if you receive no reply.