comparison doc/setup.txt @ 62:2df27f49c320 trunk

The order of extraction methods is now preserved (see #10).
author cmlenz
date Fri, 08 Jun 2007 12:41:00 +0000
parents 7dbcbc3f07e0
children c75fa55a65b9
comparison
equal deleted inserted replaced
61:9d13b9a5d727 62:2df27f49c320
56 --omit-header do not include msgid "" entry in header 56 --omit-header do not include msgid "" entry in header
57 --output-file (-o) name of the output file 57 --output-file (-o) name of the output file
58 --width (-w) set output line width (default 76) 58 --width (-w) set output line width (default 76)
59 --no-wrap do not break long message lines, longer than the 59 --no-wrap do not break long message lines, longer than the
60 output line width, into several lines 60 output line width, into several lines
61 --input-dirs directories that should be scanned for messages
61 62
62 Running the command will produce a PO template file:: 63 Running the command will produce a PO template file::
63 64
64 $ ./setup.py extract_messages --output-file foobar/locale/messages.pot 65 $ ./setup.py extract_messages --output-file foobar/locale/messages.pot
65 running extract_messages 66 running extract_messages
81 .. code-block:: python 82 .. code-block:: python
82 83
83 setup(... 84 setup(...
84 85
85 message_extractors = { 86 message_extractors = {
86 'foobar/**.py': ('python', None), 87 'foobar': [
87 'foobar/**/templates/**.html': ('genshi', None), 88 ('**.py', ('python', None),
88 'foobar/**/templates/**.txt': ('genshi', { 89 ('**/templates/**.html', ('genshi', None),
89 'template_class': 'genshi.template.text.TextTemplate' 90 ('**/templates/**.txt', ('genshi', {
90 }) 91 'template_class': 'genshi.template.text.TextTemplate'
92 })
93 ],
91 }, 94 },
92 95
93 ... 96 ...
94 ) 97 )
95 98
122 | ``--width`` (``-w``) | set output line width (default 76) | 125 | ``--width`` (``-w``) | set output line width (default 76) |
123 +-----------------------------+----------------------------------------------+ 126 +-----------------------------+----------------------------------------------+
124 | ``--no-wrap`` | do not break long message lines, longer than | 127 | ``--no-wrap`` | do not break long message lines, longer than |
125 | | the output line width, into several lines | 128 | | the output line width, into several lines |
126 +-----------------------------+----------------------------------------------+ 129 +-----------------------------+----------------------------------------------+
130 | ``--input-dirs`` | directories that should be scanned for |
131 | | messages |
132 +-----------------------------+----------------------------------------------+
Copyright (C) 2012-2017 Edgewall Software