mirror of
https://github.com/jupyter/notebook.git
synced 2025-01-24 12:05:22 +08:00
Merge pull request #8150 from minrk/bigsplit-nbconvert
Big Split: nbconvert -> jupyter_nbconvert
This commit is contained in:
commit
8c8c5905dc
@ -1,31 +0,0 @@
|
||||
"""Python script Exporter class"""
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# 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
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
from .templateexporter import TemplateExporter
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Classes
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
class PythonExporter(TemplateExporter):
|
||||
"""
|
||||
Exports a Python code file.
|
||||
"""
|
||||
def _file_extension_default(self):
|
||||
return '.py'
|
||||
|
||||
def _template_file_default(self):
|
||||
return 'python'
|
||||
|
||||
output_mimetype = 'text/x-python'
|
25
setupbase.py
25
setupbase.py
@ -175,10 +175,20 @@ def find_package_data():
|
||||
|
||||
os.chdir(os.path.join('tests',))
|
||||
js_tests = glob('*.js') + glob('*/*.js')
|
||||
|
||||
os.chdir(os.path.join(cwd, 'IPython', 'nbconvert'))
|
||||
nbconvert_templates = [os.path.join(dirpath, '*.*')
|
||||
for dirpath, _, _ in os.walk('templates')]
|
||||
|
||||
# nbconvert package_data:
|
||||
# os.chdir(os.path.join(cwd, 'IPython', 'nbconvert'))
|
||||
# nbconvert_templates = [os.path.join(dirpath, '*.*')
|
||||
# for dirpath, _, _ in os.walk('templates')]
|
||||
# package_data = {
|
||||
# 'IPython.nbconvert.filters' : ['marked.js'],
|
||||
# 'IPython.nbconvert' : nbconvert_templates +
|
||||
# [
|
||||
# 'tests/files/*.*',
|
||||
# 'exporters/tests/files/*.*',
|
||||
# 'preprocessors/tests/files/*.*',
|
||||
# ],
|
||||
# }
|
||||
|
||||
os.chdir(cwd)
|
||||
|
||||
@ -189,13 +199,6 @@ def find_package_data():
|
||||
'IPython.testing.plugin' : ['*.txt'],
|
||||
'IPython.html' : ['templates/*'] + static_data,
|
||||
'IPython.html.tests' : js_tests,
|
||||
'IPython.nbconvert' : nbconvert_templates +
|
||||
[
|
||||
'tests/files/*.*',
|
||||
'exporters/tests/files/*.*',
|
||||
'preprocessors/tests/files/*.*',
|
||||
],
|
||||
'IPython.nbconvert.filters' : ['marked.js'],
|
||||
# 'IPython.nbformat' : [
|
||||
# 'tests/*.ipynb',
|
||||
# 'v3/nbformat.v3.schema.json',
|
||||
|
Loading…
Reference in New Issue
Block a user