How can I effectively use CC++ and WSL together in Visual Studio Code?

2026-04-16 19:551阅读0评论SEO资讯
  • 内容介绍
  • 文章标签
  • 相关推荐

本文共计142个文字,预计阅读时间需要1分钟。

How can I effectively use C/C++ and WSL together in Visual Studio Code?

参考以下修改后的内容:

使用remote-wsl和coderunner进行配置,具体步骤如下:

1.设置参考:[https://www.zhihu.com/question/333233461/answer/769838167](https://www.zhihu.com/question/333233461/answer/769838167)

2.在launch.json中重点设置pipeProgram,格式为:

json pipeProgram: bash.exe /usr : C:\\Users

remote-wsl和coderunner参考:www.zhihu.com/question/333233461/answer/769838167

设置参考:code.visualstudio.com/docs/editor/variables-reference,重点launch.json中

How can I effectively use C/C++ and WSL together in Visual Studio Code?

pipeProgram": "bash.exe" "/usr": "C:\\Users\\<my windows user name>\\AppData\\Local\\Packages\\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\\LocalState\\rootfs\\usr\\"

vscode变量参考:code.visualstudio.com/docs/editor/variables-reference,重点是${fileDirname}和${fileBasenameNoExtension}

本文共计142个文字,预计阅读时间需要1分钟。

How can I effectively use C/C++ and WSL together in Visual Studio Code?

参考以下修改后的内容:

使用remote-wsl和coderunner进行配置,具体步骤如下:

1.设置参考:[https://www.zhihu.com/question/333233461/answer/769838167](https://www.zhihu.com/question/333233461/answer/769838167)

2.在launch.json中重点设置pipeProgram,格式为:

json pipeProgram: bash.exe /usr : C:\\Users

remote-wsl和coderunner参考:www.zhihu.com/question/333233461/answer/769838167

设置参考:code.visualstudio.com/docs/editor/variables-reference,重点launch.json中

How can I effectively use C/C++ and WSL together in Visual Studio Code?

pipeProgram": "bash.exe" "/usr": "C:\\Users\\<my windows user name>\\AppData\\Local\\Packages\\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\\LocalState\\rootfs\\usr\\"

vscode变量参考:code.visualstudio.com/docs/editor/variables-reference,重点是${fileDirname}和${fileBasenameNoExtension}