Open ngharrison opened 4 years ago
Thanks for your feedback! You mean that this feature would be able to run blocks one after the other, a bit like Jupyter?
Yes, similar to that. The idea of code blocks or code cells. The Matlab IDE does this itself using %%
.
There is similar functionality in Python IDEs (Jupyter, Spyder, VSCode Python extension) with some delimiter such as #%%
.
One more thing I'd add on is to have the focus stay in the editor when code (selection, line, block, etc.) is run. Currently it always takes me to the terminal and I have to click back into the editor to run the next line.
These would be nice features. I'm not sure how complicated they would be.
Here is my workaround for cell evaluation:
This solution requires the Vim extension.
I have also mapped <Ctrl+A> to toggle focus between the editor and terminal.
Yes, similar to that. The idea of code blocks or code cells. The Matlab IDE does this itself using
%%
. There is similar functionality in Python IDEs (Jupyter, Spyder, VSCode Python extension) with some delimiter such as#%%
.One more thing I'd add on is to have the focus stay in the editor when code (selection, line, block, etc.) is run. Currently it always takes me to the terminal and I have to click back into the editor to run the next line.
These would be nice features. I'm not sure how complicated they would be.
Check out this issue/pullrequest Adding "Cursor Back to Editor" function for "Run Current Selection". It solves your second problem.
I think "splitting code into blocks" should be an independent functionality. I'm working on it. Here is a demo. I'll integrate it into this extension soon and hope can implement the "run code blocks" functionality.
Almost done (if there is no unexpected bugs).
Just a feature suggestion. The ability to run blocks of code delimited by
%%
would be very useful. Thanks for the great extension!