vscode文件配置

lanuch.json

{
    "version": "0.2.0",
    "configurations": [

      {
        "name": "(gdb) 启动",
        "type": "cppdbg",
        "request": "launch",
        // "program": "输入程序名称,例如 ${workspaceFolder}/a.exe",
        "program": "${fileDirname}\\${fileBasenameNoExtension}.exe",
        "args": [],
        "stopAtEntry": false,
        "cwd": "${fileDirname}",
        "environment": [],
        "externalConsole": false,
        "MIMode": "gdb",
        "miDebuggerPath": "E:\\vscode\\mingw\\bin\\gdb.exe",
        "setupCommands": [
            {
                "description": "为 gdb 启用整齐打印",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            },
            {
                "description": "将反汇编风格设置为 Intel",
                "text": "-gdb-set disassembly-flavor intel",
                "ignoreFailures": true
            }
        ]
      },

      {
        // "justMyCode":false,
        "name": "(gdb) Launch", 
        "type": "cppdbg", 
        "request": "launch", 
        "program": "${fileDirname}\\${fileBasenameNoExtension}.exe", 
        "args": [], 
        "stopAtEntry": false,
        "cwd": "${workspaceRoot}",
        "environment": [],
        "externalConsole": true, 
        "MIMode": "gdb",
        "miDebuggerPath": "E:\\vscode\\mingw\\bin\\gdb.exe",
        "preLaunchTask": "g++",
        "setupCommands": [
          {
            "description": "Enable pretty-printing for gdb",
            "text": "-enable-pretty-printing",
            "ignoreFailures": true
          }
        ]
      }
    ]
  }

tasks.json

{
	"version": "2.0.0",
	"tasks": [
		{
			"type": "cppbuild",
			"label": "g++",
			"command": "E:/vscode/mingw/bin/g++.exe",
			"args": [
				"-fdiagnostics-color=always",
				"-g",
				"${file}",
				"-o",
				"${fileDirname}\\${fileBasenameNoExtension}.exe",
			],
			"options": {
				"cwd": "E:/vscode/mingw/bin"
			},
			"problemMatcher": [
				"$gcc"
			],
			"group": {
				"kind": "build",
				"isDefault": true
			},
			"detail": "编译器: E:/vscode/mingw/bin/g++.exe"
		}
	]
 

}

c_cpp_properties.json

{
    "configurations": [
        {
            "name": "Win32",
            "includePath": [
                "${workspaceFolder}/**"
            ],
            "defines": [
                "_DEBUG",
                "UNICODE",
                "_UNICODE"
            ],
            "compilerPath": "E:/vscode/mingw/bin/g++.exe",
            "cStandard": "c17",
            "cppStandard": "gnu++14",
            "intelliSenseMode": "gcc-x64"
        }
    ],
    "version": 4
}

相关推荐

  1. vscode文件配置

    2024-01-11 14:14:03       55 阅读
  2. VSCode配置json文件 C语言篇

    2024-01-11 14:14:03       38 阅读
  3. vscode debug ts文件-配置参考】

    2024-01-11 14:14:03       32 阅读

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-01-11 14:14:03       98 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-01-11 14:14:03       106 阅读
  3. 在Django里面运行非项目文件

    2024-01-11 14:14:03       87 阅读
  4. Python语言-面向对象

    2024-01-11 14:14:03       96 阅读

热门阅读

  1. 隐藏服务器IP的正确使用方式

    2024-01-11 14:14:03       56 阅读
  2. flutter中枚举的使用

    2024-01-11 14:14:03       61 阅读
  3. 部署 Spring Boot 应用中文文档

    2024-01-11 14:14:03       39 阅读
  4. Spring Boot 自动装配原理

    2024-01-11 14:14:03       55 阅读
  5. Socket.D v2.3 发布(打通前端与后端)

    2024-01-11 14:14:03       64 阅读
  6. 【PostgreSQL】外部数据

    2024-01-11 14:14:03       63 阅读
  7. 数据结构英文习题解析-第二章 链表List

    2024-01-11 14:14:03       47 阅读