Metadata-Version: 1.0
Name: pystache
Version: 0.4.0
Summary: Mustache for Python
Home-page: http://github.com/defunkt/pystache
Author: Chris Wanstrath
Author-email: chris@ozmm.org
License: MIT
Description: ========
        Pystache
        ========
        
        .. image:: https://s3.amazonaws.com/webdev_bucket/pystache.png
        
        Inspired by ctemplate_ and et_, Mustache_ is a
        framework-agnostic way to render logic-free views.
        
        As ctemplates says, "It emphasizes separating logic from presentation:
        it is impossible to embed application logic in this template language."
        
        Pystache is a Python implementation of Mustache. Pystache requires
        Python 2.6.
        
        Pystache is semantically versioned: http://semver.org.
        
        Logo: David Phillips - http://davidphillips.us/ 
        
        Documentation
        =============
        
        The different Mustache tags are documented at `mustache(5)`_.
        
        Install It
        ==========
        
        ::
        
            pip install pystache
        
        
        Use It
        ======
        
        ::
        
            >>> import pystache
            >>> pystache.render('Hi {{person}}!', {'person': 'Mom'})
            'Hi Mom!'
        
        You can also create dedicated view classes to hold your view logic.
        
        Here's your simple.py::
        
            import pystache
            class Simple(pystache.View):
                def thing(self):
                    return "pizza"
        
        Then your template, simple.mustache::
        
            Hi {{thing}}!
        
        Pull it together::
        
            >>> Simple().render()
            'Hi pizza!'
        
        
        Test It
        =======
        
        nose_ works great! ::
        
            pip install nose
            cd pystache
            nosetests
        
        
        Mailing List
        ==================
        As of Nov 26, 2011, there's a mailing list, pystache@librelist.com.
        
        Archive: http://librelist.com/browser/pystache/
        
        Note: There's a bit of a delay in seeing the latest emails appear
        in the archive.
        
        Author
        ======
        
        ::
        
            context = { 'author': 'Chris Wanstrath', 'email': 'chris@ozmm.org' }
            pystache.render("{{author}} :: {{email}}", context)
        
        
        .. _ctemplate: http://code.google.com/p/google-ctemplate/
        .. _et: http://www.ivan.fomichev.name/2008/05/erlang-template-engine-prototype.html
        .. _Mustache: http://defunkt.github.com/mustache/
        .. _mustache(5): http://mustache.github.com/mustache.5.html
        .. _nose: http://somethingaboutorange.com/mrl/projects/nose/0.11.1/testing.html
        
        History
        =======
        
        0.4.0 (2011-01-12)
        ------------------
        * Add support for nested contexts (within template and view)
        * Add support for inverted lists
        * Decoupled template loading
        
        0.3.1 (2010-05-07)
        ------------------
        
        * Fix package
        
        0.3.0 (2010-05-03)
        ------------------
        
        * View.template_path can now hold a list of path
        * Add {{& blah}} as an alias for {{{ blah }}}
        * Higher Order Sections
        * Inverted sections
        
        0.2.0 (2010-02-15)
        ------------------
        
        * Bugfix: Methods returning False or None are not rendered
        * Bugfix: Don't render an empty string when a tag's value is 0. [enaeseth]
        * Add support for using non-callables as View attributes. [joshthecoder]
        * Allow using View instances as attributes. [joshthecoder]
        * Support for Unicode and non-ASCII-encoded bytestring output. [enaeseth]
        * Template file encoding awareness. [enaeseth]
        
        0.1.1 (2009-11-13)
        ------------------
        
        * Ensure we're dealing with strings, always
        * Tests can be run by executing the test file directly
        
        0.1.0 (2009-11-12)
        ------------------
        
        * First release
        
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.5
Classifier: Programming Language :: Python :: 2.6
