annotate textshaper/template.py @ 5:0a800613af9a

textshaper/main.py
author Jeff Hammel <jhammel@mozilla.com>
date Thu, 26 Sep 2013 02:02:36 -0700
parents 53cfd6e1ad0f
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
1 #!/usr/bin/env python
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
2
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
3 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
4 TextShaper template for makeitso
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
5 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
6
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
7 import sys
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
8 from cli import MakeItSoCLI
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
9 from optparse import OptionParser
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
10 from template import MakeItSoTemplate
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
11
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
12 class TextShaperTemplate(MakeItSoTemplate):
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
13 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
14 TextShaper template
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
15 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
16 name = 'TextShaper'
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
17 templates = ['template']
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
18 look = True
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
19
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
20 class TemplateCLI(MakeItSoCLI):
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
21 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
22 CLI driver for the TextShaper template
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
23 """
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
24
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
25 def main(args=sys.argv[:]):
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
26 cli = TemplateCLI()
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
27 cli(*args)
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
28
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
29 if __name__ == '__main__':
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
30 main()
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
31
53cfd6e1ad0f initial commit,
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
32