Skip to content
Myr

setup.py

This file

Path

setup.py

110 lines · 3.2 KiB · Python

Last changed by

master will be 2.6Armin Ronacherbefore adoption44e1f56

History of this file

Take it

The walk stopped after 200 commits: lines older than 4ef9234 point at it.

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

lines 1–39why, one step back
1# -*- coding: utf-8 -*-
2"""3Jinja24~~~~~~56Jinja2 is a template engine written in pure Python. It provides a7`Django`_ inspired non-XML syntax but supports inline expressions and8an optional `sandboxed`_ environment.910Nutshell11--------1213Here a small example of a Jinja template::1415 {% extends 'base.html' %}16 {% block title %}Memberlist{% endblock %}17 {% block content %}18 <ul>19 {% for user in users %}20 <li><a href="{{ user.url }}">{{ user.username }}</a></li>21 {% endfor %}22 </ul>23 {% endblock %}2425Philosophy26----------2728Application logic is for the controller but don't try to make the life29for the template designer too hard by giving him too few functionality.3031For more informations visit the new `Jinja2 webpage`_ and `documentation`_.3233.. _sandboxed: http://en.wikipedia.org/wiki/Sandbox_(computer_security)34.. _Django: http://www.djangoproject.com/35.. _Jinja2 webpage: http://jinja.pocoo.org/36.. _documentation: http://jinja.pocoo.org/2/documentation/37"""38import sys39

Documented switch to MarkupSafeArmin Ronacherbefore adoption10c34da

line 40why, one step back
40from setuptools import setup, Extension, Feature

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

line 41why, one step back
41

Documented switch to MarkupSafeArmin Ronacherbefore adoption10c34da

lines 42–50why, one step back
42debugsupport = Feature(
43 'optional C debug support',44 standard=False,45 ext_modules = [46 Extension('jinja2._debugsupport', ['jinja2/_debugsupport.c']),47 ],48)4950

Propably delaying release for better python 3 support. Started working onArmin Ronacherbefore adoption0faa861

lines 51–57why, one step back
51# tell distribute to use 2to3 with our own fixers.
52extra = {}53if sys.version_info >= (3, 0):54 extra.update(55 use_2to3=True,56 use_2to3_fixers=['custom_fixers']57 )

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

line 58why, one step back
58

Preparing for a 2.5.2 release. Fixed an issue with setup.pyArmin Ronacherbefore adoption4603694

lines 59–61why, one step back
59# ignore the old '--with-speedups' flag
60try:61 speedups_pos = sys.argv.index('--with-speedups')

Unbroke setup.pyArmin Ronacherbefore adoptionfe22512

line 62why, one step back
62except ValueError:

Preparing for a 2.5.2 release. Fixed an issue with setup.pyArmin Ronacherbefore adoption4603694

lines 63–65why, one step back
63 pass
64else:65 sys.argv[speedups_pos] = '--with-debugsupport'

Improved message and unbroke 3.xArmin Ronacherbefore adoptionc4538a8

lines 66–72why, one step back
66 sys.stderr.write('*' * 74 + '\n')
67 sys.stderr.write('WARNING:\n')68 sys.stderr.write(' the --with-speedups flag is deprecated, assuming '69 '--with-debugsupport\n')70 sys.stderr.write(' For the actual speedups install the MarkupSafe '71 'package.\n')72 sys.stderr.write('*' * 74 + '\n')

experimental Python 3 support.Armin Ronacherbefore adoption0319c66

line 73why, one step back
73

Preparing for a 2.5.2 release. Fixed an issue with setup.pyArmin Ronacherbefore adoption4603694

line 74why, one step back
74

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

lines 75–76why, one step back
75setup(
76 name='Jinja2',

master will be 2.6Armin Ronacherbefore adoption44e1f56

line 77why, one step back
77 version='2.6',

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

lines 78–93why, one step back
78 url='http://jinja.pocoo.org/',
79 license='BSD',80 author='Armin Ronacher',81 author_email='armin.ronacher@active-4.com',82 description='A small but fast and easy to use stand-alone template '83 'engine written in pure python.',84 long_description=__doc__,85 # jinja is egg safe. But we hate eggs86 zip_safe=False,87 classifiers=[88 'Development Status :: 5 - Production/Stable',89 'Environment :: Web Environment',90 'Intended Audience :: Developers',91 'License :: OSI Approved :: BSD License',92 'Operating System :: OS Independent',93 'Programming Language :: Python',

Untagged and added python 3 category.Armin Ronacherbefore adoptiond9599c8

line 94why, one step back
94 'Programming Language :: Python :: 3',

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

lines 95–98why, one step back
95 'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
96 'Topic :: Software Development :: Libraries :: Python Modules',97 'Topic :: Text Processing :: Markup :: HTML'98 ],

MarkupSafe is now used for the Jinja2 speedupsArmin Ronacherbefore adoptionf9f5f26

lines 99–100why, one step back
99 packages=['jinja2', 'jinja2.testsuite', 'jinja2.testsuite.res',
100 'jinja2._markupsafe'],

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

line 101why, one step back
101 extras_require={'i18n': ['Babel>=0.8']},

Started working on unittest powered testsuite.Armin Ronacherbefore adoption7af781c

line 102why, one step back
102 test_suite='jinja2.testsuite.suite',

Approaching python3 compatibilityArmin Ronacherbefore adoption790b8a8

line 103why, one step back
103 include_package_data=True,

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

lines 104–106why, one step back
104 entry_points="""
105 [babel.extractors]106 jinja2 = jinja2.ext:babel_extract[i18n]

experimental Python 3 support.Armin Ronacherbefore adoption0319c66

line 107why, one step back
107 """,

Documented switch to MarkupSafeArmin Ronacherbefore adoption10c34da

line 108why, one step back
108 features={'debugsupport': debugsupport},

Propably delaying release for better python 3 support. Started working onArmin Ronacherbefore adoption0faa861

line 109why, one step back
109 **extra

Clarified copyrights.Armin Ronacherbefore adoption4ef9234

line 110why, one step back
110)