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

Ask user if they want to send shift-enter to Interactive Window #3647

Closed
IanMatthewHuff opened this issue Jan 28, 2019 · 7 comments
Closed
Assignees

Comments

@IanMatthewHuff
Copy link
Member

First time shift enter + Jupyter installed = prompt user to ask for changing the global setting to send shift-enter to ipython window.

@IanMatthewHuff IanMatthewHuff self-assigned this Jan 28, 2019
@EED85
Copy link

EED85 commented Feb 12, 2019

Hi @IanMatthewHuff ,
that is a great idea.
What I would like more is, that I have one Shortcut for running a cell and another one for running the selected code within terminal

So within an .py file in "Jupyter Style" (#%% Run Cell), I can easily decide, if the code shall run on Jupyter or Terminal.

Eric

@IanMatthewHuff
Copy link
Member Author

@EED85 Hmm, I think that our current implementation does actually hide the send to terminal command when you start sending selection to the interactive windows instead. But I see your point that both command could be useful. I'll look into it.

@EED85
Copy link

EED85 commented Feb 23, 2019

thx :-)

@rchiodo rchiodo closed this as completed Apr 24, 2019
@aldanor
Copy link

aldanor commented May 19, 2019

What I would like more is, that I have one Shortcut for running a cell and another one for running the selected code within terminal

Indeed, would be great to have both; it would be much more flexible than a global setting.

Use case: I have a running kernel with tons of loaded stuff; being still able to send things to terminal lets me quickly test out things and scripts without touching the main kernel.

@rchiodo
Copy link
Contributor

rchiodo commented May 20, 2019

@aldanor , I believe what you're asking for is already possible within VS Code.

If you go to File | Keyboard Shortcuts, you can get to something like this:
image

In that image I double clicked on the second 'Run Selection' command and changed the keyboard shortcut to 'ALT+ENTER'. Now 'SHIFT+ENTER' sends a cell/line to the interactive window and 'ALT+ENTER' sends it to the terminal.

@EED85
Copy link

EED85 commented May 21, 2019

Hi,
I am using the same shortcut for both (shift+Enter).
When the Cursor is in a cell, then the code will be executed within PYthon interactive
when code is highlithed it will be executed in the terminal

@EED85
Copy link

EED85 commented May 21, 2019

VSCODE - Run python code - terminal - interactive

@lock lock bot locked as resolved and limited conversation to collaborators Jun 2, 2019
@microsoft microsoft unlocked this conversation Nov 14, 2020
@DonJayamanne DonJayamanne transferred this issue from microsoft/vscode-python Nov 14, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants