Skip to content

Instantly share code, notes, and snippets.

@TrQ-Hoan
Created October 23, 2022 08:46
Show Gist options
  • Save TrQ-Hoan/976bf537409e78b4faa58e205e94d298 to your computer and use it in GitHub Desktop.
Save TrQ-Hoan/976bf537409e78b4faa58e205e94d298 to your computer and use it in GitHub Desktop.
Simple vs-code config msvc
{
"configurations": [
{
"name": "Win32",
"includePath": [
"C:/Program Files (x86)/Windows Kits/8.1/Include/**",
"C:/Program Files (x86)/Windows Kits/10/Include/10.0.10240.0/ucrt",
"C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include",
"${default}",
"${workspaceFolder}",
"${workspaceFolder}/**"
],
"defines": [
"_DEBUG",
"UNICODE",
"_UNICODE"
],
"intelliSenseMode": "windows-msvc-x86",
"browse": {
"path": [
"C:/Program Files (x86)/Windows Kits/10/Lib/10.0.10240.0/ucrt/**",
"C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin",
"C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/lib"
],
"limitSymbolsToIncludedHeaders": true,
"databaseFilename": ""
},
//"cStandard": "c11",
//"cppStandard": "c++17",
// "configurationProvider": "ms-vscode.cpptools",
"compilerPath": "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/cl.exe"
}
],
"version": 4
}
{
"version": "0.2.0",
"configurations": [
{
"name": "C/C++: cl.exe build and debug active file",
"type": "cppvsdbg",
"request": "launch",
"program": "${fileDirname}\\${fileBasenameNoExtension}.exe",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"console": "externalTerminal",
"preLaunchTask": "C/C++: cl.exe build active file"
}
]
}
{
"C_Cpp.clang_format_fallbackStyle": "{ BasedOnStyle: Google, IndentWidth: 4, ColumnLimit: 0}",
"files.associations": {
"winternl.h": "c"
}
}
{
"version": "2.0.0",
"windows": {
"options": {
"shell": {
"executable": "cmd.exe",
"args": [
"/C",
"\"C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\vcvarsall.bat\"",
// "amd64",
"&&"
]
}
}
},
"tasks": [
{
"type": "shell",
"label": "C/C++: cl.exe build active file",
"command": "cl.exe",
"args": [
// "Zi",
"/D_X86_",
// "/D_AMD64_",
"/EHsc",
"/MT",
"/Fo:${fileDirname}\\Release\\",
"/Fe:${fileDirname}\\Release\\${fileBasenameNoExtension}.exe",
"${file}",
"/link",
"/NODEFAULTLIB",
"/ENTRY:main",
"/MANIFEST",
// "/MANIFESTUAC:\"level='requireAdministrator' uiAccess='false'\"",
"/MANIFESTUAC:\"level='requireAdministrator'\"",
// "/SUBSYSTEM:WINDOWS",
"/MACHINE:X86",
// "user32.lib", "msvcrt.lib", // #param comment(lib, "user32.lib")
"kernel32.lib", "libcmt.lib", "libvcruntime.lib", "ucrt.lib", "msvcmrt.lib", "shell32.lib"
],
"problemMatcher": [
"$msCompile"
],
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment