Sync from SUSE:SLFO:Main python-Mako revision b704c2a74da097b324949c452e499363

This commit is contained in:
Adrian Schröter 2024-05-03 19:49:28 +02:00
commit 59e06b667d
4 changed files with 721 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
Mako-1.2.4.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

600
python-Mako.changes Normal file
View File

@ -0,0 +1,600 @@
-------------------------------------------------------------------
Sat Dec 3 03:26:25 UTC 2022 - Yogalakshmi Arunachalam <yarunachalam@suse.com>
- Update to 1.2.4
[bug] [codegen] Fixed issue where unpacking nested tuples in a for loop using would raise a
"couldn't apply loop context" error if the loop context was used. The regex
used to match the for loop expression now allows the list of loop variables
to contain parenthesized sub-tuples. Pull request courtesy Matt Trescott.
-------------------------------------------------------------------
Thu Sep 29 19:44:07 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.2.3:
* Fixed issue in lexer in the same category as that of :ticket:`366` where
the regexp used to match an end tag didn't correctly organize for matching
characters surrounded by whitespace, leading to high memory / interpreter
hang if a closing tag incorrectly had a large amount of unterminated space
in it. Credit to Sebastian Chnelik for locating the issue.
* As Mako templates inherently render and directly invoke arbitrary Python
code from the template source, it is **never** appropriate to create
templates that contain untrusted input.
-------------------------------------------------------------------
Sun Sep 11 07:28:33 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.2.2:
* Fixed issue in lexer where the regexp used to match tags would not
correctly interpret quoted sections individually
-------------------------------------------------------------------
Mon Jul 18 13:39:44 UTC 2022 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 1.2.1:
* [bug] [tests] Various fixes to the test suite in the area of exception
message rendering to accommodate for variability in Python versions as
well as Pygments.
* [performance] Optimized some codepaths within the lexer/Python code
generation process, improving performance for generation of templates
prior to their being cached. Pull request courtesy Takuto Ikuta.
* [changed] [py3k] Corrected "universal wheel" directive in setup.cfg so
that building a wheel does not target Python 2.
* [changed] [py3k] The bytestring_passthrough template argument is removed,
as this flag only applied to Python 2.
* [changed] [py3k] With the removal of Python 2's cStringIO, Mako now uses
its own internal FastEncodingBuffer exclusively.
* [changed] Refactored test utilities into mako.testing module. Removed
unittest.TestCase dependency in favor of pytest.
* [changed] [setup] Replaced the use of pkg_resources with the importlib
library. For Python < 3.8 the library importlib_metadata is used.
* [changed] [py3k] Removed support for Python 2 and Python 3.6. Mako now
requires Python >= 3.7.
* [bug] [py3k] Mako now performs exception chaining using raise from,
correctly identifying underlying exception conditions when it raises its
own exceptions. Pull request courtesy Ram Rachum.
- Remove python2 gubbins, since it is no longer supported.
-------------------------------------------------------------------
Thu Mar 24 09:22:40 UTC 2022 - pgajdos@suse.com
- python-mock is not required for build
-------------------------------------------------------------------
Mon Dec 6 09:47:44 UTC 2021 - Dirk Müller <dmueller@suse.com>
- update to 1.1.6:
* Fixed issue where control statements on multi lines with a backslash would
not parse correctly if the template itself contained CR/LF pairs as on
Windows.
-------------------------------------------------------------------
Sat Oct 16 19:02:49 UTC 2021 - Dirk Müller <dmueller@suse.com>
- update to 1.1.5:
* Fixed some issues with running the test suite which would
be revealed by running tests in random order.
-------------------------------------------------------------------
Wed Oct 6 07:34:14 UTC 2021 - Matej Cepl <mcepl@suse.com>
- Remove obsolete %suse_version %if
-------------------------------------------------------------------
Tue Oct 5 14:45:17 UTC 2021 - Stefan Schubert <schubi@suse.de>
- Added BuildRequires: alts
-------------------------------------------------------------------
Thu Sep 30 15:22:55 UTC 2021 - Stefan Schubert <schubi@schubi.de>
- Use libalternatives instead of update-alternatives.
-------------------------------------------------------------------
Sun Jan 24 19:48:33 UTC 2021 - Dirk Müller <dmueller@suse.com>
- update to 1.1.4:
* Fixed Python deprecation issues related to module importing, as well as
file access within the Lingua plugin, for deprecated APIs that began to
emit warnings under Python 3.10.
-------------------------------------------------------------------
Fri Dec 11 23:26:38 UTC 2020 - Benjamin Greiner <code@bnavigator.de>
- Let the python-rpm-macros do their job for the correct provides
and obsoletes tags for multiple python3 flavors
gh#openSUSE/python-rpm-macros#66
-------------------------------------------------------------------
Mon Jun 8 08:54:52 UTC 2020 - Ondřej Súkup <mimi.vx@gmail.com>
- update to 1.1.3
* The default template encoding is now utf-8
-------------------------------------------------------------------
Mon May 25 06:50:43 UTC 2020 - Petr Gajdos <pgajdos@suse.com>
- %python3_only -> %python_alternative
-------------------------------------------------------------------
Mon Mar 2 08:38:32 UTC 2020 - Ondřej Súkup <mimi.vx@gmail.com>
- update to 1.1.2
* Added output-file argument to the Mako command line runner
-------------------------------------------------------------------
Tue Feb 18 17:01:27 UTC 2020 - Ondřej Súkup <mimi.vx@gmail.com>
- update to 1.1.1
* Replaced usage of the long-superseded “parser.suite” module in the mako.util
package for parsing the python magic encoding comment with the “ast.parse” function
* Added “babel” and “lingua” dependency entries to the setuptools entrypoints
for the babel and lingua extensions
-------------------------------------------------------------------
Mon Aug 5 11:42:51 UTC 2019 - pgajdos@suse.com
- version update to 1.1.0
* Removed the "python setup.py test" feature in favor
* Replaced usage of ``inspect.getfullargspec()`` with the vendored version
used by SQLAlchemy, Alembic to avoid future deprecation warnings.
-------------------------------------------------------------------
Mon Jul 29 07:36:52 UTC 2019 - pgajdos@suse.com
- version update to 1.0.14
* The n filter is now supported in the <%page> tag. This allows a template to omit the default expression filters throughout a whole template, for those cases where a
template-wide filter needs to have default filtering disabled.
* Fixed issue where the correct file URI would not be shown in the template-formatted exception traceback if the template filename were not known. Additionally fixes an issue
where stale filenames would be displayed if a stack trace alternated between different templates.
* Improved the line-number tracking for source lines inside of Python <% ... %> blocks, such that text- and HTML-formatted exception traces such as that of
html_error_template() now report the correct source line inside the block, rather than the first line of the block itself. Exceptions in <%! ... %> blocks which get raised
while loading the module are still not reported correctly, as these are handled before the Mako code is generated.
-------------------------------------------------------------------
Tue Jun 18 08:40:22 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 1.0.12:
* Fixed regression where import refactors in Mako 1.0.11 caused broken imports on Python 3.8.
* Updated for additional project metadata in setup.py. Additionally, the code has been reformatted using Black and zimports.
-------------------------------------------------------------------
Thu May 16 17:09:40 UTC 2019 - kwu@suse.com
- Update to 1.0.10:
* Added default encoding for Python 3 for traceback.
-------------------------------------------------------------------
Mon Apr 29 08:01:43 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 1.0.9:
* Fixed an element in the AST Python generator which changed for Python 3.8
-------------------------------------------------------------------
Thu Mar 21 13:36:46 UTC 2019 - Ondřej Súkup <mimi.vx@gmail.com>
- update to 1.0.8
* Added --output-encoding flag to the mako-render script
-------------------------------------------------------------------
Thu Jul 5 21:47:54 UTC 2018 - mcepl@suse.com
- Clean up SPEC file.
-------------------------------------------------------------------
Tue Mar 6 16:53:30 UTC 2018 - aplanas@suse.com
- Allows Recommends and Suggest in Fedora
-------------------------------------------------------------------
Tue Feb 27 17:48:11 UTC 2018 - aplanas@suse.com
- Recommends only for SUSE
-------------------------------------------------------------------
Mon Aug 21 16:58:43 UTC 2017 - tbechtold@suse.com
- update to 1.0.7:
* Changed the "print" in the mako-render command to
sys.stdout.write(), avoiding the extra newline at the end
of the template output.
-------------------------------------------------------------------
Sat May 6 03:31:54 UTC 2017 - toddrme2178@gmail.com
- Don't provide python2-mako, singlespec packages should use
correct name.
-------------------------------------------------------------------
Tue Apr 11 09:15:31 UTC 2017 - jengelh@inai.de
- Trim extreme wording of description
-------------------------------------------------------------------
Thu Apr 6 11:38:50 UTC 2017 - jmatejek@suse.com
- restore compatibility Provides
-------------------------------------------------------------------
Wed Mar 1 16:14:57 UTC 2017 - aloisio@gmx.com
- Converted to single-spec
- Switched source URL to pypi.io
- Removed update-alternative
-------------------------------------------------------------------
Fri Feb 10 16:06:00 UTC 2017 - michael@stroeder.com
- update to version 1.0.6
* [feature] Added new parameter Template.include_error_handler .
This works like Template.error_handler but indicates the
handler should take place when this template is included within
another template via the <%include> tag. Pull request courtesy
Huayi Zhang.
* [bug] Updated the Sphinx documentation builder to work with recent
versions of Sphinx.
-------------------------------------------------------------------
Wed Nov 16 06:57:29 UTC 2016 - tbechtold@suse.com
- python-Beaker is only recommended, not required.
-------------------------------------------------------------------
Fri Sep 16 04:04:40 UTC 2016 - toddrme2178@gmail.com
- update to version 1.0.4:
* [test] [feature] The default test runner is now py.test. Running
“python setup.py test” will make use of py.test instead of
nose. nose still works as a test runner as well, however.
* [lexer] [bug] Major improvements to lexing of intricate Python
sections which may contain complex backslash sequences, as well as
support for the bitwise operator (e.g. pipe symbol) inside of
expression sections distinct from the Mako “filter” operator,
provided the operator is enclosed within parentheses or
brackets. Pull request courtesy Daniel Martin.
* [feature] Added new method Template.list_defs(). Pull request
courtesy Jonathan Vanasco.
- update to version 1.0.3:
* Fixed an issue where the Babel plugin would not handle a
translation symbol that contained non-ascii characters. Pull
request courtesy Roman Imankulov.
- Update to version 1.0.2
* The "universal wheel" marker is removed from setup.cfg, because
our setup.py currently makes use of conditional dependencies.
In :ticket:`249`, the discussion is ongoing on how to correct our
setup.cfg / setup.py fully so that we can handle the per-version
dependency changes while still maintaining optimal wheel settings,
so this issue is not yet fully resolved.
* Repair some calls within the ast module that no longer work on Python3.5;
additionally replace the use of ``inspect.getargspec()`` under
Python 3 (seems to be called from the TG plugin) to avoid deprecation
warnings.
* Update the Lingua translation extraction plugin to correctly
handle templates mixing Python control statements (such as if,
for and while) with template fragments. Pull request courtesy
Laurent Daverio.
* Added ``STOP_RENDERING`` keyword for returning/exiting from a
template early, which is a synonym for an empty string ``""``.
Previously, the docs suggested a bare
``return``, but this could cause ``None`` to appear in the
rendered template result.
- Implement update-alternatives
-------------------------------------------------------------------
Fri Jul 24 19:45:09 UTC 2015 - seife+obs@b1-systems.com
- fix non-SUSE distro build by conditionalizing Suggests: tag
-------------------------------------------------------------------
Fri Mar 13 11:43:52 UTC 2015 - p.drouand@gmail.com
- update to version 1.0.1:
* [feature] Added support for Lingua, a translation extraction
system as an alternative to Babel. Pull request courtesy Wichert
Akkerman.
* [bug] [py3k] Modernized the examples/wsgi/run_wsgi.py file for
Py3k. Pull requset courtesy Cody Taylor.
- Disable temporary tests for non-Factory systems because of failures
-------------------------------------------------------------------
Tue Jul 29 21:17:21 UTC 2014 - dmueller@suse.com
- fix up build for SLE11
-------------------------------------------------------------------
Fri Jul 18 14:43:53 UTC 2014 - toddrme2178@gmail.com
- Update to version 1.0.0
+ Too many changes; please look at changelog in package documentation
-------------------------------------------------------------------
Thu Mar 6 14:26:53 UTC 2014 - speilicke@suse.com
- Only suggest Beaker, it's an extra requirement and not really needed
-------------------------------------------------------------------
Mon Jan 13 13:20:54 UTC 2014 - dmueller@suse.com
- update to 0.9.1:
- [bug] Fixed bug in Babel plugin where translator comments
would be lost if intervening text nodes were encountered.
Fix courtesy Ned Batchelder. [ticket:225]
- [bug] Fixed TGPlugin.render method to support unicode template
names in Py2K - courtesy Vladimir Magamedov.
- [bug] Fixed an AST issue that was preventing correct operation
under alpha versions of Python 3.4. Pullreq courtesy Zer0-.
- [bug] Changed the format of the "source encoding" header output
by the code generator to use the format ``# -*- coding:%s -*-``
instead of ``# -*- encoding:%s -*-``; the former is more common
and compatible with emacs. Courtesy Martin Geisler.
- [bug] Fixed issue where an old lexer rule prevented a template line
which looked like "#*" from being correctly parsed. [ticket:224]
-------------------------------------------------------------------
Tue Sep 3 08:20:48 UTC 2013 - dmueller@suse.com
- update to 0.9.0:
- [bug] The Context.locals_() method becomes a private underscored
method, as this method has a specific internal use. The purpose
of Context.kwargs has been clarified, in that it only delivers
top level keyword arguments originally passed to template.render().
[ticket:219]
- [bug] Fixed the babel plugin to properly interpret ${} sections
inside of a "call" tag, i.e. <%self:some_tag attr="${_('foo')}"/>.
Code that's subject to babel escapes in here needs to be
specified as a Python expression, not a literal. This change
is backwards incompatible vs. code that is relying upon a _('')
translation to be working within a call tag.
- [bug] The Babel plugin has been repaired to work on Python 3.
[ticket:187]
- [bug] Using <%namespace import="*" module="somemodule"/> now
skips over module elements that are not explcitly callable,
avoiding TypeError when trying to produce partials.
[ticket:207]
- [bug] Fixed Py3K bug where a "lambda" expression was not
interpreted correctly within a template tag; also
fixed in Py2.4. [ticket:190]
-------------------------------------------------------------------
Tue Jun 25 11:58:53 UTC 2013 - dmueller@suse.com
- update to 0.8.1:
- [bug] Changed setup.py to skip installing markupsafe
if Python version is < 2.6 or is between 3.0 and
less than 3.3, as Markupsafe now only supports 2.6->2.X,
3.3->3.X. [ticket:216]
- [bug] Fixed regression where "entity" filter wasn't
converted for py3k properly (added tests.)
[ticket:214]
- [bug] Fixed bug where mako-render script wasn't
compatible with Py3k. [ticket:212]
- [bug] Cleaned up all the various deprecation/
file warnings when running the tests under
various Pythons with warnings turned on.
[ticket:213]
- [feature] Performance improvement to the
"legacy" HTML escape feature, used for XML
escaping and when markupsafe isn't present,
courtesy George Xie.
- [bug] Fixed bug whereby an exception in Python 3
against a module compiled to the filesystem would
fail trying to produce a RichTraceback due to the
content being in bytes. [ticket:209]
- [bug] Change default for compile()->reserved_names
from tuple to frozenset, as this is expected to be
a set by default. [ticket:208]
- [feature] Code has been reworked to support Python 2.4->
Python 3.xx in place. 2to3 no longer needed.
- [feature] Added lexer_cls argument to Template,
TemplateLookup, allows alternate Lexer classes
to be used.
- [feature] Added future_imports parameter to Template
and TemplateLookup, renders the __future__ header
with desired capabilities at the top of the generated
template module. Courtesy Ben Trofatter.
-------------------------------------------------------------------
Thu Nov 22 14:53:41 UTC 2012 - saschpe@suse.de
- Update to version 0.7.3:
+ [bug] legacy_html_escape function, used when
Markupsafe isn't installed, was using an inline-compiled
regexp which causes major slowdowns on Python 3.3;
is now precompiled.
+ [bug] AST supporting now supports tuple-packed
function arguments inside pure-python def
or lambda expressions.
+ [bug] Fixed Py3K bug in the Babel extension.
+ [bug] Fixed the "filter" attribute of the
<%text> tag so that it pulls locally specified
identifiers from the context the same
way as that of <%block> and <%filter>.
+ [bug] Fixed bug in plugin loader to correctly
raise exception when non-existent plugin
is specified.
- Changes from version 0.7.2:
+ [bug] Fixed regression in 0.7.1 where AST
parsing for Py2.4 was broken.
- Changes from version 0.7.1:
+ [feature] Control lines with no bodies will
now succeed, as "pass" is added for these
when no statements are otherwise present.
+ [bug] Fixed some long-broken scoping behavior
involving variables declared in defs and such,
which only became apparent when
the strict_undefined flag was turned on.
+ [bug] Can now use strict_undefined at the
same time args passed to def() are used
by other elements of the <%def> tag.
- Don't give the Python2 binary the prefix "python3"
-------------------------------------------------------------------
Fri May 25 08:33:12 UTC 2012 - toddrme2178@gmail.com
- Fix building on openSUSE 11.4
- spec file cleanups
-------------------------------------------------------------------
Wed May 23 05:57:47 UTC 2012 - highwaystar.ru@gmail.com
- python3 package added
- Update to 0.7.0
- Added new "loop" variable to templates, is provided within a %
for block to provide info about the loop such as index,
first/last, odd/even, etc. A migration path is also provided
for legacy templates via the "enable_loop" argument available
on Template, TemplateLookup, and <%page>.
- Added a real check for "reserved" names, that is names which
are never pulled from the context and cannot be passed to the
template.render() method. Current names are "context", "loop",
"UNDEFINED".
- The html_error_template() will now apply Pygments highlighting
to the source code displayed in the traceback, if Pygments if
available.
- Added support for context managers,
i.e. "% with x as e:/ % endwith" support.
- Added class-level flag to CacheImpl "pass_context"; when True,
the keyword argument 'context' will be passed to
get_or_create() containing the Mako Context object.
- Added Jinja2 to the example benchmark suite
- Bugfixes
- Update to 0.6.2
- Bugfixes
- Update to 0.6.1
- Bugfixes
- Update to 0.6.0
- Template caching has been converted into a plugin system,
whereby the usage of Beaker is just the default plugin.
Template and TemplateLookup now accept a string "cache_impl"
parameter which refers to the name of a cache plugin,
defaulting to the name 'beaker'. New plugins can be registered
as pkg_resources entrypoints under the group "mako.cache", or
registered directly using mako.cache.register_plugin(). The
core plugin is the mako.cache.CacheImpl class.
- Added support for Beaker cache regions in templates. Usage of
regions should be considered as superseding the very obsolete
idea of passing in backend options, timeouts, etc. within
templates.
- The 'put' method on Cache is now 'set'. 'put' is there for
backwards compatibility.
- The <%def>, <%block> and <%page> tags now accept any argument
named "cache_*", and the key minus the "cache_" prefix will be
passed as keyword arguments to the CacheImpl methods.
- Template and TemplateLookup now accept an argument cache_args,
which refers to a dictionary containing cache parameters. The
cache_dir, cache_url, cache_type, cache_timeout arguments are
deprecated (will probably never be removed, however) and can be
passed now as cache_args={'url':<some url>, 'type':'memcached',
'timeout':50, 'dir':'/path/to/some/directory'}
- Can now refer to context variables within extra arguments to
<%block>, <%def>,
i.e. <%block name="foo" cache_key="${somekey}">. Filters can
also be used in this way,
i.e. <%def name="foo()" filter="myfilter"> then
template.render(myfilter=some_callable)
- Added "--var name=value" option to the mako-render script,
allows passing of kw to the template from the command line.
- Added module_writer argument to Template, TemplateLookup,
allows a callable to be passed which takes over the writing of
the template's module source file, so that special
environment-specific steps can be taken.
- Bugfixes
-------------------------------------------------------------------
Thu Nov 10 10:53:53 UTC 2011 - saschpe@suse.de
- Update to version 0.5.0:
* A Template is explicitly disallowed from having a url that
normalizes to relative outside of the root. [ticket:174]
-------------------------------------------------------------------
Thu Sep 1 14:10:31 UTC 2011 - saschpe@suse.de
- Added python-nose BuildRequires for testsuite and packages make-render
binary
-------------------------------------------------------------------
Thu Sep 1 13:23:11 UTC 2011 - saschpe@suse.de
- Update to version 0.4.2:
* Fixed bug regarding <%call>/def calls w/ content whereby the identity
of the "caller" callable inside the <%def> would be corrupted by the
presence of another <%call> in the same block. [ticket:170]
* Fixed the babel plugin to accommodate <%block> [ticket:169]
- Simpler spec file
-------------------------------------------------------------------
Thu Jul 1 18:24:17 UTC 2010 - jfunk@funktronics.ca
- Update to 0.3.4
- Now using MarkupSafe for HTML escaping,
i.e. in place of cgi.escape(). Faster
C-based implementation and also escapes
single quotes for additional security.
Supports the __html__ attribute for
the given expression as well.
When using "disable_unicode" mode,
a pure Python HTML escaper function
is used which also quotes single quotes.
Note that Pylons by default doesn't
use Mako's filter - check your
environment.py file.
- Fixed call to "unicode.strip" in
exceptions.text_error_template which
is not Py3k compatible. [ticket:137]
-------------------------------------------------------------------
Tue Sep 8 12:26:28 UTC 2009 - jfunk@funktronics.ca
- Update to 0.2.5
- Added a "decorator" kw argument to <%def>, allows custom decoration
functions to wrap rendering callables. Mainly intended for custom caching
algorithms, not sure what other uses there may be (but there may be).
Examples are in the "filtering" docs.
- When Mako creates subdirectories in which to store templates, it uses the
more permissive mode of 0775 instead of 0750, helping out with certain
multi-process scenarios. Note that the mode is always subject to the
restrictions of the existing umask. [ticket:101]
- Fixed namespace.__getattr__() to raise AttributeError on attribute not
found instead of RuntimeError. [ticket:104]
- Added last_modified accessor to Template, returns the time.time() when the
module was created. [ticket:97]
- Fixed lexing support for whitespace around '=' sign in defs. [ticket:102]
- Removed errant "lower()" in the lexer which was causing tags to compile
with case-insensitive names, thus messing up custom <%call> names.
[ticket:108]
- added "mako.__version__" attribute to the base module. [ticket:110]
-------------------------------------------------------------------
Thu Sep 3 14:07:58 CEST 2009 - matejcik@suse.cz
- build as noarch
-------------------------------------------------------------------
Thu Sep 3 13:28:41 CEST 2009 - matejcik@suse.cz
- importing package from OBS, original changelog follows
* Mon Aug 10 2009 - Ciaran Farrell <cfarrell1980@gmail.com> - 0.2.4-1
- Update to 0.2.4
* Tue Dec 02 2008 - James Oakley <jfunk@funktronics.ca> - 0.2.3-1
- Initial release

95
python-Mako.spec Normal file
View File

@ -0,0 +1,95 @@
#
# spec file for package python-Mako
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%if 0%{?suse_version} > 1500
%bcond_without libalternatives
%else
%bcond_with libalternatives
%endif
Name: python-Mako
Version: 1.2.4
Release: 0
Summary: A Python templating language
License: MIT
URL: https://www.makotemplates.org/
Source: https://files.pythonhosted.org/packages/source/M/Mako/Mako-%{version}.tar.gz
BuildRequires: %{python_module MarkupSafe >= 0.9.2}
BuildRequires: %{python_module base >= 3.7}
BuildRequires: %{python_module pbr}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros >= 20210929
Requires: python-MarkupSafe >= 0.9.2
Requires: python-setuptools
%if %{with libalternatives}
Requires: alts
BuildRequires: alts
%else
Requires(post): update-alternatives
Requires(postun):update-alternatives
%endif
BuildArch: noarch
Recommends: python-Beaker >= 1.1
Provides: python-mako = %{version}
Obsoletes: python-mako < %{version}
%python_subpackages
%description
Mako is a template library written in Python. It provides a non-XML
syntax which compiles into Python modules for performance. Mako's
syntax and API borrows from Django templates, Cheetah, Myghty, and
Genshi. Conceptually, Mako is an embedded Python (i.e. Python Server
Page) language, which refines the ideas of componentized layout and
inheritance, while maintaining close ties to Python calling and
scoping semantics.
%prep
%setup -q -n Mako-%{version}
%build
%python_build
%install
%python_install
%python_clone -a %{buildroot}%{_bindir}/mako-render
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%pytest
%pre
# If libalternatives is used: Removing old update-alternatives entries.
%python_libalternatives_reset_alternative mako-render
%post
%python_install_alternative mako-render
%postun
%python_uninstall_alternative mako-render
%files %{python_files}
%license LICENSE
%doc CHANGES README.rst
%doc examples
%python_alternative %{_bindir}/mako-render
%{python_sitelib}/mako/
%{python_sitelib}/Mako-%{version}-py*.egg-info
%changelog