##// END OF EJS Templates
Remove generation of unnecessary generated.rst file
klonuo -
Show More
@@ -7,7 +7,6 b' from ipykernel.kernelapp import IPKernelApp'
7
7
8 here = abspath(dirname(__file__))
8 here = abspath(dirname(__file__))
9 options = join(here, 'source', 'config', 'options')
9 options = join(here, 'source', 'config', 'options')
10 generated = join(options, 'generated.rst')
11
10
12 def write_doc(name, title, app, preamble=None):
11 def write_doc(name, title, app, preamble=None):
13 filename = '%s.rst' % name
12 filename = '%s.rst' % name
@@ -18,18 +17,12 b' def write_doc(name, title, app, preamble=None):'
18 if preamble is not None:
17 if preamble is not None:
19 f.write(preamble + '\n\n')
18 f.write(preamble + '\n\n')
20 f.write(app.document_config_options())
19 f.write(app.document_config_options())
21 with open(generated, 'a') as f:
22 f.write(filename + '\n')
23
20
24
21
25 if __name__ == '__main__':
22 if __name__ == '__main__':
26 # create empty file
27 with open(generated, 'w'):
28 pass
29
23
30 write_doc('terminal', 'Terminal IPython options', TerminalIPythonApp())
24 write_doc('terminal', 'Terminal IPython options', TerminalIPythonApp())
31 write_doc('kernel', 'IPython kernel options', IPKernelApp(),
25 write_doc('kernel', 'IPython kernel options', IPKernelApp(),
32 preamble=("These options can be used in :file:`ipython_kernel_config.py`. "
26 preamble=("These options can be used in :file:`ipython_kernel_config.py`. "
33 "The kernel also respects any options in `ipython_config.py`"),
27 "The kernel also respects any options in `ipython_config.py`"),
34 )
28 )
35
General Comments 0
You need to be logged in to leave comments. Login now