Latest updates for C++ Remote Linux Development in Visual Studio: Remote File Explorer, Integrated Terminal, and more…

Sinem Akinci

Visual Studio allows you to target your remote Linux machines so that you can still use Visual Studio’s build and debugging suite for all your remote workflows just like how you would develop locally without having to leave the IDE. To further enhance your ability to develop remotely for C++ from Visual Studio, we have added a new Remote File Explorer to perform file operations on your remote machine, an integrated SSH terminal to access your remote targets, and an automated experience to install Windows Subsystem for Linux (WSL) and build tools. Additionally, we have added support to run remote Linux tests from the Test Explorer.

To access the full Linux support for C++ in Visual Studio, download it via the Linux and embedded development with C++ workload.

Image linux embedded2

Remote File Explorer

The Remote File Explorer allows you to access your files and folders on your remote machines that you are connected to through the Connection Manager without having to leave the IDE. In C++ projects, Visual Studio will automatically detect all WSL connections when you use CMake Presets to build your project. To add a new remote connection to a machine that isn’t WSL through the Connection Manager, please see our documentation.

The remote File explorer window in Visual Studio with the folder hierarchy.

To access the Remote File Explorer, navigate to View > Remote File Explorer in Visual Studio after downloading it through the Linux and Embedded Workflow in the VS Installer.

the remote filee explorer for linux selected under the linux and embedded development workload

You can perform file operations from here such as:

  • Viewing your files
  • Editing your files
  • Searching for your files and navigating to the remote path
  • Uploading files
  • Downloading files
  • Viewing the output of file operations

To learn more about the Remote File Explorer’s capabilities, please see our blog post announcements: View files on your Remote Machines using the new Remote File Explorer in Visual Studio – C++ Team Blog (microsoft.com) and What’s New for the Remote File Explorer in Visual Studio – C++ Team Blog (microsoft.com). If there is anything you would like to see added to this view, please comment on our open feedback ticket here.

Integrated Terminal

Users can now leverage the Visual Studio’s integrated terminal to access their remote targets when developing for remote machines from Windows, via an interactive SSH shell. It can be accessed by going to View>Terminal.

The integrated terminal showing a squirrel in color.

Instead of having to start a separate SSH session inside of PowerShell or WSL and having to re-authenticate, you can select one of your existing connections from the Connection Manager or WSL. You only have to authenticate once when you add a stored connection. To add a new remote connection to a machine that isn’t WSL through the Connection Manager, please see our documentation. In the upper-left corner of the integrated terminal, you can click on the SSH connection and see the options enumerated from your Connection Manager.

The target machine dropdown in the integrated terminal.

Additionally, the new integrated terminal now supports manipulating files, running background tasks, configuring your remote system, and testing your deployed code all from inside of VS instead of having to use an external SSH client. This terminal also supports color and command sequences, so for example, copy, paste, and find shortcuts will work, as well as interactive programs like vim.

For more information, please see our blog post here.

Automatically Install WSL from Visual Studio

Downloading WSL and its associated dev tools is now easier than ever, so you can get started with Linux development and spin up a new WSL instance with a few simple clicks.

All you need to do is navigate to Project > Install WSL For Me.

The Project dropdown in Visual Studio shows the option to Install WSL for me.

From there, an installation dialog will pop up that will automatically check the status of the pre-requisites on your machine. After the pre-requisites are run and all pass, the installation process will kick off.

the full WSL installation dialog

At the end, you can select “Finish” and the new WSL machine will be installed with all the build tools you need for development after you complete a reboot. You can then target this machine from your existing project to get started with Linux development or provision a new machine.

Added support for remote Linux unit tests in Test Explorer

In partnership with some of our customers such as the Azure Networking team, we have added support for remote Linux unit tests to be run and debugger from the Test Explorer in CMake projects. Now, when you target Linux, you can use the Test Explorer in Visual Studio like you would locally. To open this view, you can navigate to Test > Test Explorer.

The test explorer in the Visual Studio window showing remote Linux Ctests.

Read more about our partnership in our blog post.

Wrap up

We appreciate the time you’ve spent reporting issues/suggestions and hope you continue to give us feedback when using Visual Studio on what you like and what we can improve. Your feedback is critical to help us make Visual Studio the best tool it can be! You can share feedback with us via Developer Community: report any bugs or issues via report a problem and share your suggestions for new features or improvements to existing ones.

Stay connected with the Visual Studio team by following us on YouTube, Twitter, LinkedIn, Twitch and on Microsoft Learn.

6 comments

Discussion is closed. Login to edit/delete existing comments.

  • Ingram, Greg 4

    This is awesome stuff! Do you have a link that show a basic roadmap of other related features in the works? Understanding things change/slip, it would be great to see what’s to come. Thank you again.

    • Sinem AkinciMicrosoft employee 0

      Hi Greg,

      Thank you so much for the feedback! Currently, we don’t have a public link for basic roadmaps for Linux in VS, but I try to call out upcoming features in my blog posts in the C++ blog. Some to call out coming up would be further integrating the Remote File Explorer with the Integrated Terminal, adding WSL support to the CMake Debugger, and improving the Connection Manager. If there’s anything you’d like to see, please let us know! We can be reached at visualcpp@microsoft.com.

      Thanks again,
      Sinem

  • Guy 0

    I saw the headline “…Remote Linux Development in Visual Studio…”. I got all excited. Then as I was reading the article I read “for all your remote workflows just like how you would develop locally without having to leave the IDE”. More excitement!

    Then it all went downhill 🥲😟😭

    “To further enhance your ability to develop remotely for C++ from Visual Studio”

    I wish the headline was clearer and not misleading.

    When will this be available for any language and any project? As the line says “how you would develop locally”

    I was expecting C# and ASP.NET Core.

    Still waiting. . . . When will the features like that in VS Code be available? VS Code Remote Development

    • Sinem AkinciMicrosoft employee 0

      Hi Guy,

      Apologies for the headline, I updated to explicitly call out C++! That being said, you can use the Remote File Explorer for any language as long as you download the appropriate workload.

  • john chen 0

    Connection manager not working after update:
    1> Error: Could not connect to the remote system or the connection was lost.
    Target host is ubuntu(20.04), was ok yesterday.
    Connection is definitely fine, could ssh to host using CMD, connection via vs code is also fine.

Feedback usabilla icon