Added project template for VSCode (only Windows for now).
This commit is contained in:
6
util/vscode_project_template/extensions.json
Normal file
6
util/vscode_project_template/extensions.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"recommendations": [
|
||||
"ms-vscode.cpptools",
|
||||
"llvm-vs-code-extensions.vscode-clangd"
|
||||
]
|
||||
}
|
||||
18
util/vscode_project_template/launch.json.jinja
Normal file
18
util/vscode_project_template/launch.json.jinja
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"configurations": [
|
||||
{% for executable in project.executables %}
|
||||
{% set build_type_name = build_type | capitalize -%}
|
||||
{
|
||||
"name": "Debug {{ executable.name }}",
|
||||
"type": "cppvsdbg",
|
||||
"request": "launch",
|
||||
"program": "{{ executable.filename | escape_path }}",
|
||||
"args": [],
|
||||
"stopAtEntry": false,
|
||||
"cwd": "${workspaceFolder}",
|
||||
"environment": [],
|
||||
"console": "integratedTerminal"
|
||||
}
|
||||
{% endfor %}
|
||||
]
|
||||
}
|
||||
69
util/vscode_project_template/tasks.json.jinja
Normal file
69
util/vscode_project_template/tasks.json.jinja
Normal file
@@ -0,0 +1,69 @@
|
||||
{
|
||||
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
||||
// for the documentation about the tasks.json format
|
||||
"version": "2.0.0",
|
||||
"tasks": [
|
||||
{% for executable in project.executables %}
|
||||
{% for build_type in project.build_types %}
|
||||
{% set build_type_name = build_type | capitalize -%}
|
||||
{
|
||||
"label": "{{ executable.name }} {{ build_type_name }}",
|
||||
"type": "shell",
|
||||
"command": "{{ scons_exe | escape_path }} -j{{ nproc }} --build_type={{ build_type }} --unity=disable {{ executable.filename | escape_path }} compile_commands.json",
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": [],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"label": "{{ executable.name }} {{ build_type_name }} Clean",
|
||||
"type": "shell",
|
||||
"command": "{{ scons_exe | escape_path }} --build_type={{ build_type }} --unity=disable {{ executable.filename | escape_path }} -c",
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": [],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": false
|
||||
}
|
||||
},
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% for library in project.libraries %}
|
||||
{% for build_type in project.build_types %}
|
||||
{% set build_type_name = build_type | capitalize -%}
|
||||
{
|
||||
"label": "{{ library.name }} {{ build_type_name }}",
|
||||
"type": "shell",
|
||||
"command": "{{ scons_exe | escape_path }} -j{{ nproc }} --build_type={{ build_type }} --unity=disable {{ library.filename | escape_path }} compile_commands.json",
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": [],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"label": "{{ library.name }} {{ build_type_name }} Clean",
|
||||
"type": "shell",
|
||||
"command": "{{ scons_exe | escape_path }} --build_type={{ build_type }} --unity=disable {{ library.filename | escape_path }} -c",
|
||||
"options": {
|
||||
"cwd": "${workspaceFolder}"
|
||||
},
|
||||
"problemMatcher": [],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": false
|
||||
}
|
||||
},
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user