the overoverkill patch
This commit is contained in:
1 parent
a3da2916e3
commit
21616cab41
1 file changed
+5
-126
Vendored
+5
-126
@@ -25,7 +25,7 @@
|
||||
"kind": "build",
|
||||
"isDefault": true
|
||||
},
|
||||
"detail": "Automatically detects and uses available C++ compiler (g++ or MSVC)",
|
||||
"detail": "🚀 Smart build - auto-detects g++ or MSVC",
|
||||
"presentation": {
|
||||
"echo": true,
|
||||
"reveal": "always",
|
||||
@@ -56,142 +56,21 @@
|
||||
},
|
||||
"problemMatcher": ["$gcc", "$msCompile"],
|
||||
"group": "build",
|
||||
"detail": "Build optimized release version with auto-detected compiler"
|
||||
},
|
||||
{
|
||||
"type": "cppbuild",
|
||||
"label": "C++: Build with g++ (Debug)",
|
||||
"command": "g++",
|
||||
"args": [
|
||||
"-std=c++17",
|
||||
"-Wall",
|
||||
"-Wextra",
|
||||
"-g",
|
||||
"-O0",
|
||||
"${file}",
|
||||
"-o",
|
||||
"${workspaceFolder}\\build\\debug\\${fileBasenameNoExtension}.exe"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": ["$gcc"],
|
||||
"group": "build",
|
||||
"detail": "Build current file with g++ in debug mode",
|
||||
"presentation": {
|
||||
"echo": true,
|
||||
"reveal": "always",
|
||||
"focus": false,
|
||||
"panel": "shared",
|
||||
"showReuseMessage": true,
|
||||
"clear": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "cppbuild",
|
||||
"label": "C++: Build with g++ (Release)",
|
||||
"command": "C:\\msys64\\ucrt64\\bin\\g++.exe",
|
||||
"args": [
|
||||
"-std=c++17",
|
||||
"-Wall",
|
||||
"-Wextra",
|
||||
"-O2",
|
||||
"-DNDEBUG",
|
||||
"${file}",
|
||||
"-o",
|
||||
"${workspaceFolder}\\build\\release\\${fileBasenameNoExtension}.exe"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": ["$gcc"],
|
||||
"group": "build",
|
||||
"detail": "Build current file with g++ in release mode"
|
||||
},
|
||||
{
|
||||
"type": "cppbuild",
|
||||
"label": "C++: Build with g++ (MSYS2 Full Path)",
|
||||
"command": "C:\\msys64\\ucrt64\\bin\\g++.exe",
|
||||
"args": [
|
||||
"-std=c++17",
|
||||
"-Wall",
|
||||
"-Wextra",
|
||||
"-g",
|
||||
"-O0",
|
||||
"${file}",
|
||||
"-o",
|
||||
"${workspaceFolder}\\build\\debug\\${fileBasenameNoExtension}.exe"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": ["$gcc"],
|
||||
"group": "build",
|
||||
"detail": "Build current file with g++ using explicit MSYS2 path (backup option)"
|
||||
"detail": "🎯 Optimized release build"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"label": "C++: Build with MSVC (Debug)",
|
||||
"label": "🧹 Clean Build Directory",
|
||||
"command": "powershell.exe",
|
||||
"args": [
|
||||
"-Command",
|
||||
"& { $buildDir = '${workspaceFolder}\\build\\debug'; if (-not (Test-Path $buildDir)) { New-Item -ItemType Directory -Path $buildDir -Force }; & cmd /c '\"C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\Common7\\Tools\\VsDevCmd.bat\" && cd /d \"$buildDir\" && cl.exe /std:c++17 /W4 /Zi /EHsc /MDd /Fe:\"${workspaceFolder}\\build\\debug\\${fileBasenameNoExtension}.exe\" /Fo:\"$buildDir\\${fileBasenameNoExtension}.obj\" /Fd:\"$buildDir\\${fileBasenameNoExtension}.pdb\" \"${file}\"' }"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": ["$msCompile"],
|
||||
"group": "build",
|
||||
"detail": "Build current file with MSVC in debug mode (clean intermediate files)"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"label": "C++: Run current file",
|
||||
"command": "\"${workspaceFolder}\\build\\debug\\${fileBasenameNoExtension}.exe\"",
|
||||
"args": [],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"group": {
|
||||
"kind": "test",
|
||||
"isDefault": true
|
||||
},
|
||||
"presentation": {
|
||||
"echo": true,
|
||||
"reveal": "always",
|
||||
"focus": true,
|
||||
"panel": "new"
|
||||
},
|
||||
"dependsOn": "C++: Smart Build (Auto-detect Compiler)",
|
||||
"detail": "Build and run the current C++ file"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"label": "C++: Clean build directory",
|
||||
"command": "powershell.exe",
|
||||
"args": [
|
||||
"-Command",
|
||||
"if (Test-Path \"${workspaceFolder}\\build\") { Remove-Item -Recurse -Force \"${workspaceFolder}\\build\\*\" } else { New-Item -ItemType Directory -Path \"${workspaceFolder}\\build\\debug\", \"${workspaceFolder}\\build\\release\" -Force }"
|
||||
"if (Test-Path \"${workspaceFolder}\\build\") { Remove-Item -Recurse -Force \"${workspaceFolder}\\build\\*\"; Write-Host 'Build directory cleaned! 🧹' -ForegroundColor Green } else { Write-Host 'Nothing to clean!' -ForegroundColor Yellow }"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"group": "build",
|
||||
"detail": "Clean all build artifacts and recreate build directories"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"label": "C++: Setup build directories",
|
||||
"command": "powershell.exe",
|
||||
"args": [
|
||||
"-Command",
|
||||
"New-Item -ItemType Directory -Path \"${workspaceFolder}\\build\\debug\", \"${workspaceFolder}\\build\\release\" -Force"
|
||||
],
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"group": "build",
|
||||
"detail": "Create build directories if they don't exist"
|
||||
"detail": "Clean up all build artifacts"
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in new issue
Block a user