Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.recipe.template
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Romain Courteaud
slapos.recipe.template
Commits
e2d0bb95
Commit
e2d0bb95
authored
Jan 24, 2020
by
Bryton Lacquement
🚪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jinja2: add bytes and six
parent
a240f354
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
setup.py
setup.py
+1
-0
slapos/recipe/template/jinja2_template.py
slapos/recipe/template/jinja2_template.py
+3
-2
No files found.
setup.py
View file @
e2d0bb95
...
@@ -25,6 +25,7 @@ setup(name=name,
...
@@ -25,6 +25,7 @@ setup(name=name,
include_package_data
=
True
,
include_package_data
=
True
,
install_requires
=
[
install_requires
=
[
'setuptools'
,
# namespaces
'setuptools'
,
# namespaces
'six'
,
'zc.buildout'
,
# plays with buildout
'zc.buildout'
,
# plays with buildout
'jinja2>=2.7'
,
'jinja2>=2.7'
,
],
],
...
...
slapos/recipe/template/jinja2_template.py
View file @
e2d0bb95
...
@@ -32,12 +32,13 @@ import tempfile
...
@@ -32,12 +32,13 @@ import tempfile
import
zc.buildout
import
zc.buildout
from
jinja2
import
Environment
,
StrictUndefined
,
\
from
jinja2
import
Environment
,
StrictUndefined
,
\
BaseLoader
,
TemplateNotFound
,
PrefixLoader
BaseLoader
,
TemplateNotFound
,
PrefixLoader
import
six
DEFAULT_CONTEXT
=
{
x
.
__name__
:
x
for
x
in
(
DEFAULT_CONTEXT
=
{
x
.
__name__
:
x
for
x
in
(
abs
,
all
,
any
,
bin
,
bool
,
callable
,
chr
,
complex
,
dict
,
divmod
,
abs
,
all
,
any
,
bin
,
bool
,
bytes
,
callable
,
chr
,
complex
,
dict
,
divmod
,
enumerate
,
filter
,
float
,
format
,
frozenset
,
hex
,
int
,
enumerate
,
filter
,
float
,
format
,
frozenset
,
hex
,
int
,
isinstance
,
iter
,
len
,
list
,
map
,
max
,
min
,
next
,
oct
,
ord
,
isinstance
,
iter
,
len
,
list
,
map
,
max
,
min
,
next
,
oct
,
ord
,
pow
,
repr
,
reversed
,
round
,
set
,
sorted
,
str
,
sum
,
tuple
,
zip
)}
pow
,
repr
,
reversed
,
round
,
set
,
s
ix
,
s
orted
,
str
,
sum
,
tuple
,
zip
)}
def
_assert
(
x
,
*
args
):
def
_assert
(
x
,
*
args
):
if
x
:
if
x
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment