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
dbb27169
Commit
dbb27169
authored
Feb 15, 2016
by
Rafael Monnerat
👻
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Tests (follow up buildout verbosity).
parent
f0e16ee0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
2 deletions
+70
-2
slapos/recipe/template/README.jinja2.txt
slapos/recipe/template/README.jinja2.txt
+45
-1
slapos/recipe/template/README.txt
slapos/recipe/template/README.txt
+25
-1
No files found.
slapos/recipe/template/README.jinja2.txt
View file @
dbb27169
...
...
@@ -48,6 +48,10 @@ We run buildout::
>>> print system(join('bin', 'buildout')),
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
And the template has been rendered::
...
...
@@ -177,6 +181,10 @@ Use jinja2 extensions
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('foo')
foo, template
...
...
@@ -204,6 +212,10 @@ Compute template's MD5 sum::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('foo')
template
...
...
@@ -223,10 +235,14 @@ If the md5sum doesn't match, the buildout fail::
... md5sum = 0123456789abcdef0123456789abcdef
... ''')
>>> print system(join('bin', 'buildout')),
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
While:
Installing.
Getting section template.
Initializing
part
template.
Initializing
section
template.
Error: MD5 checksum mismatch for local resource at 'foo.in'.
...
...
@@ -251,6 +267,10 @@ You can specify the mode for rendered file::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
And the generated file with have the right permissions::
...
...
@@ -289,6 +309,10 @@ imported::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('bar')
FOO !
...
...
@@ -310,6 +334,10 @@ Just like context definition, it also works with indirect values::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('bar')
FOO !
...
...
@@ -354,6 +382,10 @@ All templates can be accessed inside both folders::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('bar')
a1foo
a2foo
...
...
@@ -392,6 +424,10 @@ path)::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('bar')
a1foo
a2foo
...
...
@@ -425,6 +461,10 @@ will be installed as dependency::
foobar='dependency content'
recipe='zc.buildout:debug'
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
This way you can get options which are computed in the ``__init__`` of
the dependent recipe.
...
...
@@ -478,6 +518,10 @@ Let's just use ``buildout.cfg`` using this egg::
Uninstalling dependency.
Installing sample.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('foo')
foobar
slapos/recipe/template/README.txt
View file @
dbb27169
...
...
@@ -28,6 +28,10 @@ We run buildout::
>>> print system(join('bin', 'buildout')),
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
And the output file has been parsed by buildout itself::
...
...
@@ -76,6 +80,10 @@ And run buildout, and see the result::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('template.out')
template
...
...
@@ -94,10 +102,14 @@ If the md5sum doesn't match, the buildout fail::
... md5sum = 0123456789abcdef0123456789abcdef
... ''')
>>> print system(join('bin', 'buildout')),
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
While:
Installing.
Getting section template.
Initializing
part
template.
Initializing
section
template.
Error: MD5 checksum mismatch for local resource at 'template.in'.
...
...
@@ -123,6 +135,10 @@ You can specify the mode of the written file::
>>> print system(join('bin', 'buildout')),
Uninstalling template.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
And the generated file with have the right permissions::
...
...
@@ -158,6 +174,10 @@ will be installed as dependency::
foobar='dependency content'
recipe='zc.buildout:debug'
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
This way you can get options which are computed in the ``__init__`` of
the dependent recipe.
...
...
@@ -210,5 +230,9 @@ Let's just use ``buildout.cfg`` using this egg::
Uninstalling dependency.
Installing sample.
Installing template.
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../zc.buildout/
Not found: /tmp/.../setuptools/
Not found: /tmp/.../setuptools/
>>> cat('template.out')
foobar
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