105 |
config.read_navidoc_conf = config.navidoc_conf |
config.read_navidoc_conf = config.navidoc_conf |
106 |
|
|
107 |
if html: |
if html: |
108 |
dbg('Compiling ReST '+input) |
dbg('Compiling reST '+input) |
109 |
output = output+config.midfix+'.html' |
output = output+config.midfix+'.html' |
110 |
config.output_filename = os.path.basename(output) |
config.output_filename = os.path.basename(output) |
111 |
dbg_config('Output file: '+config.output_filename) |
dbg_config('Output file: '+config.output_filename) |
115 |
docutils.core.publish_cmdline(writer_name='html', argv=args.split()) |
docutils.core.publish_cmdline(writer_name='html', argv=args.split()) |
116 |
|
|
117 |
if latex: |
if latex: |
118 |
dbg('Compiling ReST '+input) |
dbg('Compiling reST '+input) |
119 |
output = output+config.midfix+'.latex' |
output = output+config.midfix+'.latex' |
120 |
config.output_filename = os.path.basename(output) |
config.output_filename = os.path.basename(output) |
121 |
dbg_config('Output file: '+config.output_filename) |
dbg_config('Output file: '+config.output_filename) |
161 |
|
|
162 |
def run_docutils(path): |
def run_docutils(path): |
163 |
""" |
""" |
164 |
Selects all ReST files under ``path`` directory (or the single file |
Selects all reST files under ``path`` directory (or the single file |
165 |
specified by ``path``) and forwards them to conversion method. |
specified by ``path``) and forwards them to conversion method. |
166 |
""" |
""" |
167 |
if os.path.isdir(path) and not os.path.islink(path): |
if os.path.isdir(path) and not os.path.islink(path): |