mirror of
https://github.com/wassname/jupyter_contrib_nbextensions.git
synced 2026-08-16 11:22:14 +08:00
Merge pull request #804 from jcb91/highlight_selected_word
add jupyter_highlight_selected_word nbextension
This commit is contained in:
@@ -24,6 +24,7 @@ requirements:
|
||||
- ipython_genutils
|
||||
- jupyter_contrib_core >=0.3
|
||||
- jupyter_core
|
||||
- jupyter_highlight_selected_word >=0.0.5
|
||||
- jupyter_latex_envs >=1.3.4
|
||||
- jupyter_nbextensions_configurator
|
||||
- nbconvert
|
||||
|
||||
@@ -59,6 +59,7 @@ encounter any problems.
|
||||
'ipython_genutils',
|
||||
'jupyter_contrib_core >=0.3',
|
||||
'jupyter_core',
|
||||
'jupyter_highlight_selected_word >=0.0.5',
|
||||
'jupyter_latex_envs >=1.3.4',
|
||||
'jupyter_nbextensions_configurator',
|
||||
'nbconvert',
|
||||
|
||||
@@ -8,6 +8,7 @@ from __future__ import (
|
||||
import errno
|
||||
import os
|
||||
|
||||
import jupyter_highlight_selected_word
|
||||
import latex_envs
|
||||
import psutil
|
||||
from jupyter_contrib_core.notebook_compat import nbextensions
|
||||
@@ -83,7 +84,12 @@ def toggle_install_files(install, user=False, sys_prefix=False, logger=None,
|
||||
'Installing' if install else 'Uninstalling',
|
||||
'to' if install else 'from',
|
||||
'jupyter data directory'))
|
||||
for mod in [jupyter_contrib_nbextensions, latex_envs]:
|
||||
component_nbext_packages = [
|
||||
jupyter_contrib_nbextensions,
|
||||
jupyter_highlight_selected_word,
|
||||
latex_envs,
|
||||
]
|
||||
for mod in component_nbext_packages:
|
||||
if install:
|
||||
nbextensions.install_nbextension_python(
|
||||
mod.__name__, overwrite=overwrite, symlink=symlink, **kwargs)
|
||||
|
||||
@@ -88,10 +88,11 @@ class AppTest(TestCase):
|
||||
'Expected no files created in {} but found:\n\t{}'.format(
|
||||
tree_dir, '\n\t'.join(in_this_tree)))
|
||||
installed_files.extend(in_this_tree)
|
||||
# check latex_envs got installed
|
||||
# check that dependency-provided nbexts got installed
|
||||
if 'data' in dirs:
|
||||
expected_require_paths = [
|
||||
p.replace('/', os.path.sep) + '.js' for p in [
|
||||
'highlight_selected_word/main',
|
||||
'latex_envs/latex_envs',
|
||||
]]
|
||||
for req_part in expected_require_paths:
|
||||
|
||||
Reference in New Issue
Block a user