Skip to content

Commit 4b4f4f3

Browse files
committed
VS code에서 c++ 디버깅을 하자
1 parent 01d7398 commit 4b4f4f3

File tree

3 files changed

+48
-1
lines changed

3 files changed

+48
-1
lines changed

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
.vscode
21
*.swp
32
a.out
43
tag*

.vscode/launch.json

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
// Use IntelliSense to learn about possible attributes.
3+
// Hover to view descriptions of existing attributes.
4+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5+
"version": "0.2.0",
6+
"configurations": [
7+
{
8+
"name": "clang++ - Build and debug active file",
9+
"type": "cppdbg",
10+
"request": "launch",
11+
"program": "${fileDirname}/${fileBasenameNoExtension}",
12+
"args": [],
13+
"stopAtEntry": false,
14+
"cwd": "${workspaceFolder}",
15+
"environment": [],
16+
"externalConsole": true,
17+
"MIMode": "lldb",
18+
"preLaunchTask": "C/C++: clang++ build active file"
19+
}
20+
]
21+
}

.vscode/tasks.json

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"version": "2.0.0",
3+
"tasks": [
4+
{
5+
"type": "cppbuild",
6+
"label": "C/C++: clang++ build active file",
7+
"command": "/usr/bin/clang++",
8+
"args": [
9+
"-g",
10+
"${file}",
11+
"-o",
12+
"${fileDirname}/${fileBasenameNoExtension}"
13+
],
14+
"options": {
15+
"cwd": "${workspaceFolder}"
16+
},
17+
"problemMatcher": [
18+
"$gcc"
19+
],
20+
"group": {
21+
"kind": "build",
22+
"isDefault": true
23+
},
24+
"detail": "compiler: /usr/bin/clang++"
25+
}
26+
]
27+
}

0 commit comments

Comments
 (0)