Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature request] Execute selected notebook code in console keyboard-sc / context menu option #4206

Open
idoDavid opened this issue Mar 19, 2018 · 3 comments

Comments

@idoDavid
Copy link

@idoDavid idoDavid commented Mar 19, 2018

Hi,

For productivity, it would be super useful to send selected code/cell code to be executed in the attached console.

Why:
The console attached to a notebook usually is used for debugging and experimentation, the notebook contains the eventual final "production" code - minimal and concise. Often during experimentation, you want to execute code snippets in the console and observe the output. Currently, this can be done by selecting the code, copying it to the clipboard, moving the mouse to the console tab (or using a keyboard sc) pasting the code in the console and pressing enter. Long sequence, done many times.

It would be very useful to just highlight the text/cell, and press an "evaluate in console" key combination. the focus will shift to the console and the code will be executed there.
WDYT?

@jasongrout
Copy link
Contributor

@jasongrout jasongrout commented Mar 19, 2018

I think this sounds like a great idea.

@jasongrout jasongrout added this to the Future milestone Mar 19, 2018
@BoPeng
Copy link
Collaborator

@BoPeng BoPeng commented Mar 23, 2018

This is achieved in Jupyter through the Ctrl-Shift-Enter shortcut in SoS Notebook extension, see this blog post for details.

SoS Notebook is being ported to JupyterLab. This particular feature has been discussed in #3453 and will be implemented for SoS. I do plan to submit a pull request to make this feature available for all kernels though.

@idoDavid
Copy link
Author

@idoDavid idoDavid commented Mar 25, 2018

@BoPeng Thanks for the links. I think this functionality is important enough to have it separate to a different, less common need extension.

BoPeng pushed a commit to vatlab/jupyterlab that referenced this issue Apr 11, 2018
@jasongrout jasongrout removed this from the Future milestone Sep 5, 2018
@blink1073 blink1073 added this to the Future milestone Sep 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants