• vscode c++环境配置


    vscode c++环境配置

    tasks.json

    {
    // 有关 tasks.json 格式的文档,请参见
        // https://go.microsoft.com/fwlink/?LinkId=733558
        "version": "2.0.0",
        "tasks": [
            {
                "type": "shell",
                "label": "gcc.exe build active file",
                "command": "D:\Dev-Cpp\MinGW64\bin\gcc.exe",//gcc路径
                "args": [
                    "-g",
                    "${file}",
                    "-o",
                    "${fileDirname}\hello"//运行文件名
                ],
                "options": {
                    "cwd": "D:\Dev-Cpp\MinGW64\bin"//bin路径
                },
                "problemMatcher": [
                    "$gcc"
                ],
                "group": "build"
            }
        ]
    }
    

    launch.json

    {
        // 使用 IntelliSense 了解相关属性。 
        // 悬停以查看现有属性的描述。
        // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
        "version": "0.2.0",
        "configurations": [
            {
                "name": "gcc.exe build and debug active file",
                "type": "cppdbg",
                "request": "launch",
                "program": "${fileDirname}\hello",//运行文件名
                "args": [],
                "stopAtEntry": false,
                "cwd": "${workspaceFolder}",
                "environment": [],
                "externalConsole": true,
                "MIMode": "gdb",
                "miDebuggerPath": "D:\Dev-Cpp\MinGW64\bin\gdb.exe",//gdb路径
                "setupCommands": [
                    {
                        "description": "为 gdb 启用整齐打印",
                        "text": "-enable-pretty-printing",
                        "ignoreFailures": true
                    }
                ],
                "preLaunchTask": "gcc.exe build active file"
            }
        ]
    }
    

    c_cpp_properties.json

    {
        "configurations": [
            {
                "name": "Win32",
                "includePath": [
                    "D:\Dev-Cpp\MinGW64\lib\gcc\x86_64-w64-mingw32\4.9.2\include"
                ],
                "defines": [
                    "_DEBUG",
                    "UNICODE",
                    "_UNICODE"
                ],
                "intelliSenseMode": "gcc-x64"
            }
        ],
        "version": 4
    }
    
  • 相关阅读:
    P5737 【深基7.例3】闰年展示
    P1200 [USACO1.1]你的飞碟在这儿Your Ride Is Here
    P1597 语句解析
    P5735 【深基7.例1】距离函数
    P1553 数字反转(升级版)
    P1598 垂直柱状图
    P1603 斯诺登的密码
    P5738 【深基7.例4】歌唱比赛
    Ext.GridPanel 用法总结(一)—— Grid基本用法
    使用CodeSmith快速规范开发.Net软件
  • 原文地址:https://www.cnblogs.com/qingjielaojiu/p/13551895.html
Copyright © 2020-2023  润新知