- 首先下载vs code 下载地址 地址
- 下载 c++ 插件
- 下载安装 c++编译器 我在window平台使用的是 cygwin 安装的时候 需要选择国内的镜像例如:163的镜像:http://mirrors.163.com/cygwin/, 这样安装快一些,安装过后还需将 将cygwin 添加到path
- 还有 lauch.json 的设置
{ "version": "0.2.0", "configurations": [ { "name": "(gdb) Launch", "type": "cppdbg", "request": "launch", "program": "${fileDirname}/${fileBasenameNoExtension}.exe", "args": [], "stopAtEntry": false, "cwd": "${workspaceFolder}", "environment": [], "externalConsole": true, "MIMode": "gdb", "miDebuggerPath": "C:\\cygwin64\\bin\\gdb.exe", "preLaunchTask": "g++", "setupCommands": [ { "description": "Enable pretty-printing for gdb", "text": "-enable-pretty-printing", "ignoreFailures": true } ] } ] }
转载于:https://my.oschina.net/yhmhaiming/blog/2872952