You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Disclaimer: this might be unfeasible because it might involve dynamic changes to tmLanguage files.
Now that there are more and more languages implementing ipython kernels (Julia, Go, Haskell, ...), it might make sense to expand the syntax highlighting (and by extension all the snipets/completions, ect. provided by sublime) for code cells. This would involve changing this line of SublimeIPythonNotebook.tmLanguage to be updated dynamically based on the metadata given at the top of the .ipynb JSON file.
For example, when using IJulia (ipython with julia backend), the first few lines of the .ipynb are
Actually changing the line would be easy, but the question we need to ask is whether or not we would be worried about corrupting the tmLanguage source or introducing a security issue by allowing this file to be dynamically updated.
I guess another option would be to have different tmLanguage files for each type of backend (they would be copy/paste of one another with minor changes) and we would somehow instruct sublime on which one to use based on the backend.
The text was updated successfully, but these errors were encountered:
Instructing sublime to use different tmLanguage files is easy: look for this line
view.set_syntax_file("Packages/IPython Notebook/SublimeIPythonNotebook.tmLanguage")
and change it to the syntax you want. Generating syntax files on the fly might be doable, but having them pre-made will probably not be that bad - it's not like there is new language added to IPython Notebook every day.
Disclaimer: this might be unfeasible because it might involve dynamic changes to tmLanguage files.
Now that there are more and more languages implementing ipython kernels (Julia, Go, Haskell, ...), it might make sense to expand the syntax highlighting (and by extension all the snipets/completions, ect. provided by sublime) for code cells. This would involve changing this line of
SublimeIPythonNotebook.tmLanguage
to be updated dynamically based on the metadata given at the top of the .ipynb JSON file.For example, when using IJulia (ipython with julia backend), the first few lines of the .ipynb are
whereas with a normal python based notebook we have
Actually changing the line would be easy, but the question we need to ask is whether or not we would be worried about corrupting the tmLanguage source or introducing a security issue by allowing this file to be dynamically updated.
I guess another option would be to have different tmLanguage files for each type of backend (they would be copy/paste of one another with minor changes) and we would somehow instruct sublime on which one to use based on the backend.
The text was updated successfully, but these errors were encountered: