##// END OF EJS Templates
Condense raw_mimetype and mime_type traitlets into output_mimetype
Condense raw_mimetype and mime_type traitlets into output_mimetype

File last commit:

r13832:6df9ab58
r13832:6df9ab58
Show More
python.py
33 lines | 1.1 KiB | text/x-python | PythonLexer
MinRK
add raw_format to Exporter classes...
r13664 """Python script Exporter class"""
Jonathan Frederic
Finished a rough draft of the exporters.
r10588 #-----------------------------------------------------------------------------
# Copyright (c) 2013, the IPython Development Team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-----------------------------------------------------------------------------
#-----------------------------------------------------------------------------
# Imports
#-----------------------------------------------------------------------------
Jonathan Frederic
Cleanup and refactor of API, almost complete....
r10677 from IPython.utils.traitlets import Unicode
Jonathan Frederic
Rebase changes made by hand
r12505 from .templateexporter import TemplateExporter
Jonathan Frederic
Finished a rough draft of the exporters.
r10588
#-----------------------------------------------------------------------------
# Classes
#-----------------------------------------------------------------------------
Matthias BUSSONNIER
Exporter -> TemplateExporter / BaseExporter
r12500 class PythonExporter(TemplateExporter):
Jonathan Frederic
Cleanup and refactor of API, almost complete....
r10677 """
Exports a Python code file.
"""
Jonathan Frederic
Fixed all broken references, refactored some stuff here and there,...
r10624 file_extension = Unicode(
'py', config=True,
help="Extension of the file that should be written to disk")
MinRK
add raw_format to Exporter classes...
r13664
Thomas Kluyver
Condense raw_mimetype and mime_type traitlets into output_mimetype
r13832 def _output_mimetype_default(self):
return 'text/x-python'