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: Please add support for PowerShell terminal for windows, at least as option. #70

Closed
debajyoti1990 opened this issue Mar 4, 2023 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@debajyoti1990
Copy link

PowerShell is a proper terminal, many ways better than cmd.exe. Only downside is, it is slightly slower compared to win32 based cmd.exe as PowerShell is built on .NET. By the way, VScode and lapce also implement PowerShell as default terminal.

@SpartanJ
Copy link
Owner

SpartanJ commented Mar 5, 2023

Oh, yes. It is planned. It is already supported but I wanted to be easily configurable from the editor. It's quite simple to add, I might add it for the next version. Meanwhile to use PowerShell you just need to define the SHELL global environment variable with the value "powershell.exe". ecode reads SHELL from the environment to execute it, if nothing is defined I set some for each OS by default. I already tried powershell and works just fine.

@SpartanJ SpartanJ self-assigned this Mar 5, 2023
@SpartanJ SpartanJ added the enhancement New feature or request label Mar 5, 2023
@SpartanJ
Copy link
Owner

SpartanJ commented Mar 6, 2023

New default shell configuration looks like (this is a Linux screenshot, you won't see powershell here hehe):
default-shell
ecode will try to locate all the commonly used shells and offer the option to select one of them, but it also let you configure any custom shell.
Windows will now default powershell.

@debajyoti1990
Copy link
Author

I used Linux desktop in engineering school, so figured that by seeing /usr.. 😄. Can we configure custom keybinding for opening terminal in vsplit and to toggle between editor and terminal ?

@SpartanJ
Copy link
Owner

SpartanJ commented Mar 6, 2023

yes, there are several key bindings related to that, open the keybindings at Edit -> Key Bindings, these are the defaults:

mod+alt+j=switch-to-previous-split
mod+alt+l=switch-to-next-split
mod+shift+alt+i=terminal-split-top
mod+shift+alt+j=terminal-split-left
mod+shift+alt+k=terminal-split-bottom
mod+shift+alt+l=terminal-split-right
mod+shift+alt+s=terminal-split-swap
shift+alt+i=split-top
shift+alt+j=split-left
shift+alt+k=split-bottom
shift+alt+l=split-right
shift+alt+s=split-swap

terminal-split- commands open a new terminal in the split. I usually create a new terminal in a split and switch focus between splits with mod+alt+j and l (mod is "modifier key", control key in Windows).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants