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
{{ message }}
Repository navigation
Windows PowerShell should be the default terminal program on Windows #16838
feature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesterminalGeneral terminal issues that don't fall under another labelverification-neededVerification of issue is requestedverifiedVerification succeededwindowsVS Code on Windows issues
I'd like to recommend making PowerShell the default terminal program on Windows when the user hasn't configured their path (and when the COMSPEC environment variable hasn't been explicitly set). Since PowerShell will now be the default terminal program in Windows 10 going forward (see blog post), I think it makes sense to make it the default in VS Code on Windows as well.
What do you think?
Reacted by Thomas Rayner, Keith Hill, Kirk Munro, Zachary Alexander, Kévin Gallienne, Jan Egil Ring, Zuldan, Ben Gelens, Jonathan Medd, Aleksandar Nikolić and 27 more
Reacted by Andrew Harper, Theodoor and Marco Buono
Daniel Imms (@Tyriar) looks like it is set to cmd.exe by default. That was my understanding too but someone suggested that there are cases when it isn't set; I don't have any data to back that up. Even though Windows 10 is going to default to PowerShell in the UI now, I haven't heard whether they'll change COMSPEC to point to PowerShell. Either way, since PowerShell is far better than cmd.exe for developers, it makes sense to default to it in VS Code on Windows.
If the team decides it's better to stick with COMSPEC, I might see if users of the PowerShell extension would be OK with us auto-configuring the terminal to point to PowerShell on Windows.
I'm concerned about breaking people's workflow. The little experience I do have suggests that we may be by switching this. Specifically I recall it being very slow doing trivial commands and one of my most used commands before I jumped over to Linux wasdir/w which throws a scary looking error in PS.
By default on Windows does the post mean that powershell will appear first when you search for "cmd", with cmd.exe also matching the search? Because that at least gives people a very clear option, configuring the integrated terminal is a little less trivial. It also seems preferable to rather get the Windows team to make COMSPEC point to (64-bit) Powershell rather than updating every tool to work around it? Right now I believe it points at the 32-bit version of cmd.exe by default, even on 64-bit machines.
Having powershell update the config in the meantime makes total sense though (via a messagebox?).
Daniel Imms (@Tyriar) take a look at the above commit, which implements your requirements above (I think). All except the requirement to look at x86 vs. x64 - that is not necessary, as the path is same for both.
However, taking your direction literally, it does not call processes.getWindowsShell() in the case of Win10/Powershell and therefor does not take into consideration process.env['comspec'] to allow the user to override.
Is this what you intended? Or, should processes.getWindowsShell() be updated to return Powershell instead? I realize this could have unintended effects, since getWindowsShell() seems to be called in multiple places by VSCode internally...
feature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesterminalGeneral terminal issues that don't fall under another labelverification-neededVerification of issue is requestedverifiedVerification succeededwindowsVS Code on Windows issues
Activity
dburt667 commentedon Dec 7, 2016
I absolutely agree with PowerShell being Default Term.
rkeithhill commentedon Dec 7, 2016
Agreed!!
ChrisWarwick commentedon Dec 7, 2016
Yep. Please.
laureladastra commentedon Dec 7, 2016
Couldn't agree more with the other people.
mattmcnabb commentedon Dec 7, 2016
Can't argue at all. Seems natural that it would follow the Windows default command line program.
johlju commentedon Dec 7, 2016
I agree
Tyriar commentedon Dec 7, 2016
David Wilson (@daviwil) isn't
COMSPECset by default? Is it possible to tell if it's explicitly set?tostca commentedon Dec 7, 2016
Sounds like an great idea :)
MathieuBuisson commentedon Dec 7, 2016
I do agree.
daviwil commentedon Dec 7, 2016
Daniel Imms (@Tyriar) looks like it is set to cmd.exe by default. That was my understanding too but someone suggested that there are cases when it isn't set; I don't have any data to back that up. Even though Windows 10 is going to default to PowerShell in the UI now, I haven't heard whether they'll change
COMSPECto point to PowerShell. Either way, since PowerShell is far better than cmd.exe for developers, it makes sense to default to it in VS Code on Windows.If the team decides it's better to stick with
COMSPEC, I might see if users of the PowerShell extension would be OK with us auto-configuring the terminal to point to PowerShell on Windows.Tyriar commentedon Dec 7, 2016
I'm concerned about breaking people's workflow. The little experience I do have suggests that we may be by switching this. Specifically I recall it being very slow doing trivial commands and one of my most used commands before I jumped over to Linux was
dir/wwhich throws a scary looking error in PS.By default on Windows does the post mean that powershell will appear first when you search for
"cmd", with cmd.exe also matching the search? Because that at least gives people a very clear option, configuring the integrated terminal is a little less trivial. It also seems preferable to rather get the Windows team to makeCOMSPECpoint to (64-bit) Powershell rather than updating every tool to work around it? Right now I believe it points at the 32-bit version of cmd.exe by default, even on 64-bit machines.Having powershell update the config in the meantime makes total sense though (via a messagebox?).
12 remaining items
jchadwick commentedon Jan 13, 2017
Daniel Imms (@Tyriar) take a look at the above commit, which implements your requirements above (I think). All except the requirement to look at x86 vs. x64 - that is not necessary, as the path is same for both.
However, taking your direction literally, it does not call
processes.getWindowsShell()in the case of Win10/Powershell and therefor does not take into considerationprocess.env['comspec']to allow the user to override.Is this what you intended? Or, should
processes.getWindowsShell()be updated to return Powershell instead? I realize this could have unintended effects, sincegetWindowsShell()seems to be called in multiple places by VSCode internally...Tyriar commentedon Jan 13, 2017
Thanks Jess Chadwick (@jchadwick), let's discuss in the PR.
Setting Powershell as default terminal for Windows 10+ (fixes microso…
Merge pull request #18493 from jchadwick/jchadwick/default-powershell…
Tyriar commentedon Jan 23, 2017
To verifier: check that powershell is now the default terminal shell on Windows 10
ishitatsuyuki commentedon Mar 19, 2017
Please update the documents: https://code.visualstudio.com/docs/editor/integrated-terminal
Tyriar commentedon Mar 20, 2017
Thanks Tatsuyuki Ishi (@ishitatsuyuki), created microsoft/vscode-docs#891
Setting Powershell as default terminal for Windows 10+ (fixes microso…
Merge pull request microsoft#18493 from jchadwick/jchadwick/default-p…