Say hello to the new Visual Studio terminal!

Ruben Rios

Ruben

 

Building on the momentum from the recently announced Developer PowerShell, we are excited to share the first preview of the new Visual Studio terminal. This new preview experience is part of Visual Studio version 16.3 Preview 3.

 

Rather than build everything from scratch, the Visual Studio terminal shares most of its core with the Windows Terminal. For you, that translates into a more robust terminal experience, and faster adoption of new functionality.

 

Enabling the new Visual Studio terminal

To try the terminal preview, you’ll first need to enable it by visiting the Preview Features page. Go to Tools > Options > Preview Features, enable the Experimental VS Terminal option and restart Visual Studio.

Once enabled, you can invoke it via the View > Terminal Window menu entry or via the search.

Creating Terminal profiles

Launching the terminal automatically opens an integrated PowerShell instance. However, you can customize the startup experience by using shell profiles.

With shell profiles, you can target different types of shells, invoke them using unique arguments, or even set a default shell that better fits your needs.

In future updates, we plan to optimize the experience by pre-populating the terminal with a few basic profiles. In the meantime, you can manually add additional profiles on the terminal’s Options page.

 

As an example, here’s how you can set profiles for some popular options:

Developer Command Prompt

Shell location:
C:\Windows\System32\cmd.exe
Arguments:
/k "C:\Program Files (x86)\Microsoft Visual Studio\2019\IntPreview\Common7\Tools\VsDevCmd.bat"

Developer PowerShell

Shell location:
C:\WINDOWS\system32\WindowsPowerShell\v1.0\powershell.exe
Arguments:
-NoExit -Command "& { Import-Module 'C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview_master\Common7\Tools\vsdevshell\Microsoft.VisualStudio.DevShell.dll'; Enter-VsDevShell -InstanceId f86c8b33}"

Note: You’ll need to update the above argument to match your specific configuration. You can extract the argument information by looking into the Target string for the Developer PowerShell shortcut.

WSL

Shell location:
C:\WINDOWS\sysnative\wsl.exe

 

Try it out and let us know what you think!

While we are excited to share this preview, we want to ensure a solid experience before we enable this experience in the release version of Visual Studio. As a result, the terminal will initially only be available in the preview versions of Visual Studio 2019.

As next steps, we’ll look to deliver improvements around rendering (the terminal currently needs to be resized to render correctly), accessibility and theming. We’ll also add new productivity boosters such as multiple terminal instances and deeper integration with Visual Studio.

We’d love to know how it fits your workflow and how we could further improve your terminal experience. Send us your feedback via the Developer Community portal, or via the Help > Send Feedback feature inside Visual Studio.

Ruben Rios
Ruben Rios

Program Manager 2, Visual Studio

Follow Ruben   

25 comments

  • Avatar
    Lachlan Picking

    I love the Windows Terminal, and I’m excited to see you guys implmenting it into the IDE but after only a few seconds of using it (in 16.3.0 p3), it feels very rough around the edges to me. For example: it doesn’t seem to consistently scroll to the bottom when lots of text is output, the cursor doesn’t blink, so the window doesn’t always seem obviously in focus (the titlebar colour changes but I don’t think that’s enough), the arrow keys don’t seem to browse command history (or do anything at all actually; I can’t even left/right arrow to move the cursor within a line of text).
    I’m not sure if maybe something is broken on my end or not, but if this is just the state of the feature at the moment, I think it needs a bit more polish before I could use it regularly.

    • Ruben Rios
      Ruben Rios

      Thanks for the great and detailed feedback! We are planning to bring additional stability and polish to the experience with the next few preview releases.

      This type of feedback is extremely helpful to the team… so thanks again! 🙂

  • Avatar
    James Chaldecott

    I assume this is going to need Windows 10 build 1903 (or higher) to work, like Windows Terminal?
    Presumably there won’t be a fallback for lower Windows builds/versions, and the option will just be disabled.

  • Avatar
    Alex Postlethwaite

    Good feature.
    – If I invoke ‘cls’, it seems to mess up the rendering, text just gets printed out on top of existing text.
    – It’s not happy at all if I type ‘exit’.
    – How do I close an instance so that I can get a different profile running (without terminating VS). Closing the tool window and reopening just seems to get me back the previously opened instance.

    • Ruben Rios
      Ruben Rios

      Hi Alex, at the moment the only way to terminate the instance is to restart the Visual Studio session. Once we enable the multiple instances functionality, closing the tool window will terminate the terminal instance. Thanks for the feedback!

  • Avatar
    Jason Bock

    Will there be a way to have multiple terminal windows/tabs open, similar to Windows Terminal, instead of only being able to have one open?

    • Avatar
      Rick Strahl

      Same request here – to be useful I typically need several terminals side at the same time. For example running dotnet watch run in one and a full command line for dotnet or git commands in the other.
      if that’s not there I’m going to be forced to use something else in combination which the makes the built in one moot.
      I know it’s early but please consider adding multi tab support ala vocode…

      • Ruben Rios
        Ruben Rios

        As I mentioned to Jason, the team is currently working on this same feature.

        Our plan is to include each new terminal instance on its own tool window so you can organize them separately and optimize for your needs.

        Thanks for the feedback! 🙂

      • Avatar
        Sanjeevakumar Hiremath

        Yes this will be very cool feature. However I also don’t want to see visual studio taking the role of operating system running multiple processes within, it may be slipery from there.

  • Avatar
    Don Stinchfield

    I’m using win ver 1703.  The Windows Terminal feature works with the limitations mentioned in this discussion. 
    Great feature!  Once scrolling works I’ll incorporate it into my toolbox.  I’ve wanted this in vs for a long time. Thank you!

  • Avatar
    André Köhler

    Great! Just a few days ago I was working on some very basic MSBuild scripts (you can not open/build them in Visual Studio directly) and when I wanted to invoke msbuild.exe on them I was very surprised that there was no terminal inside Visual Studio, even though every other IDE I know had one. Considering that Visual Studio is one of the greatest IDEs with the most features out there, adding a terminal was really overdue.

  • Avatar
    May, Ben

    This is SUPER COOL!
    I noticed any launch of cmd.exe runs a prompt with PROCESSOR_ARCHITECTURE=x86 instead of AMD64 is there a way to work around that?  For example I get 32bit cmd.exe instead of 64bit cmd Like I would expect when just running cmd.exe directly. 
    Also the text seems to be fixed to 50 character width, can that be customizable, or linked to the window width? I also notice that the window doesn’t scroll to the bottom or stay with the end of the output of the commands I execute.  The text width issue doesn’t seem to be a problem with wsl or powershell though.

    • Avatar
      May, Ben

      I actually noticed the text width seems to be a bug if I detach the window and move it then it changes the width and displays full width of the window.

      • Ruben Rios
        Ruben Rios

        Hi! Thanks for the feedback!

        Re: 64-bit support
        At this point we can only run the terminal in 32-bit. It would be great to understand if this impacts your scenarios negatively and the extent of the impact.

        Re: Text width/rendering issue
        This is a known issue that we are hoping to fix soon on a future preview release.

  • Avatar
    Dean Jackson

    devblogs.microsoft.com is slow to load (for /VisualStudio and individual article pages) if you are logged in, and using Firefox Windows (latest release) or Edge 18 (44.18362.1.0). If I’m not logged in, it loads faster.

Leave a comment