annotate buttercup/__init__.py @ 53:af4155b0a260 default tip

add --prefix option
author Jeff Hammel <k0scist@gmail.com>
date Tue, 03 Nov 2020 07:59:36 -0800
parents 86c3c0d4d434
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
1 from paste.script import templates
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
2
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
3 var = templates.var
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
4
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
5 class buttercup(templates.Template):
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
6 _template_dir = 'template'
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
7 summary = 'paste template for creating instances of the buttercup flower website pattern'
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
8 vars = [
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
9 var('description', 'One-line description of the package'),
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
10 var('author', 'Author name'),
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
11 var('author_email', 'Author email'),
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
12 var('url', 'URL of homepage'),
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
13 ]
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
14
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
15 def pre(self, command, output_dir, vars):
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
16 """
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
17 called before the template is applied
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
18 """
32
86c3c0d4d434 drastic rewrite; now use classes == flowers
Jeff Hammel <jhammel@mozilla.com>
parents: 6
diff changeset
19 # XXX broken for now
86c3c0d4d434 drastic rewrite; now use classes == flowers
Jeff Hammel <jhammel@mozilla.com>
parents: 6
diff changeset
20 # src = sources()
86c3c0d4d434 drastic rewrite; now use classes == flowers
Jeff Hammel <jhammel@mozilla.com>
parents: 6
diff changeset
21 # vars['install_requires'] = '\n'.join([repr(s[0])+','
86c3c0d4d434 drastic rewrite; now use classes == flowers
Jeff Hammel <jhammel@mozilla.com>
parents: 6
diff changeset
22 # for s in src])
0
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
23
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
24 def post(self, command, output_dir, vars):
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
25 """
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
26 called after the template is applied
9661071dac87 initial commit of the buttercup flower; just a stub
k0s <k0scist@gmail.com>
parents:
diff changeset
27 """