##// END OF EJS Templates
Merge pull request #6335 from jasongrout/patch-7...
Brian E. Granger -
r17694:100dd64b merge
parent child Browse files
Show More
@@ -8,7 +8,7 b' pjoin = os.path.join'
8 8
9 9 from IPython.utils.path import get_ipython_dir
10 10 from IPython.utils.py3compat import PY3
11 from IPython.utils.traitlets import HasTraits, List, Unicode, Dict
11 from IPython.utils.traitlets import HasTraits, List, Unicode, Dict, Any
12 12
13 13 if os.name == 'nt':
14 14 programdata = os.environ.get('PROGRAMDATA', None)
@@ -36,18 +36,12 b' class KernelSpec(HasTraits):'
36 36 argv = List()
37 37 display_name = Unicode()
38 38 language = Unicode()
39 codemirror_mode = None
39 codemirror_mode = Any() # can be unicode or dict
40 40 env = Dict()
41
42 41 resource_dir = Unicode()
43 42
44 def __init__(self, resource_dir, argv, display_name, language,
45 codemirror_mode=None):
46 super(KernelSpec, self).__init__(resource_dir=resource_dir, argv=argv,
47 display_name=display_name, language=language,
48 codemirror_mode=codemirror_mode)
49 if not self.codemirror_mode:
50 self.codemirror_mode = self.language
43 def _codemirror_mode_default(self):
44 return self.language
51 45
52 46 @classmethod
53 47 def from_resource_dir(cls, resource_dir):
General Comments 0
You need to be logged in to leave comments. Login now