Skip to content

Commit 7dac016

Browse files
author
mikeblome
committed
fixes per tech review
1 parent d23a2e9 commit 7dac016

3 files changed

Lines changed: 17 additions & 17 deletions

File tree

‎docs/build/launch-vs-schema-reference-cpp.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "launch.vs.json schema reference (C++)"
3-
ms.date: "08/09/2019"
3+
ms.date: "08/20/2019"
44
helpviewer_keywords: ["launch.vs.json file [C++]"]
55
---
66

@@ -24,7 +24,7 @@ Use the *launch.vs.json* file to configure debugging parameters. To create the f
2424
|noDebug|boolean|Specifies whether or not to debug the launched program. The default value for this parameter is false if not specified.|
2525
|stopOnEntry|boolean|Specifies whether or not to break a soon as the process is launched and the debugger attaches. The default value for this parameter is false.|
2626
|remoteMachine|string|Specifies the name of the remote machine where the program is launched.|
27-
|env|array|(Deprecated. Use the `env.NAME` syntax instead.) Specifies a key-value list of custom environment variables. env":{"myEnv":"myVal"}.|
27+
|env|array| Specifies a key-value list of custom environment variables. env:{"myEnv":"myVal"}.|
2828
|portName|string|Specifies the name of port when attaching to a running process.|
2929
|buildConfigurations|array| A key-value pair that specifies the name of the build mode to apply the configurations. For example `Debug` or `Release` and the configurations to use according to the selected build mode. See example below.
3030

‎docs/build/open-folder-projects-cpp.md‎

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
---
22
title: "Open Folder support for C++ build systems in Visual Studio"
3-
ms.date: "03/21/2019"
3+
ms.date: "08/20/2019"
44
helpviewer_keywords: ["Open Folder Projects in Visual Studio"]
55
ms.assetid: abd1985e-3717-4338-9e80-869db5435175
66
---
7-
# Open Folder projects for C++
7+
# Open Folder support for C++ build systems in Visual Studio
88

99
::: moniker range="vs-2015"
1010

@@ -14,7 +14,7 @@ The Open Folder feature is available in Visual Studio 2017 and later.
1414

1515
::: moniker range=">=vs-2017"
1616

17-
In Visual Studio 2017 and later, the "Open Folder" feature enables you to open a folder of source files and immediately start coding with support for IntelliSense, browsing, refactoring, debugging, and so on. As you edit, create, move, or delete files, Visual Studio tracks the changes automatically and continuously updates its IntelliSense index. No .sln or .vcxproj files are loaded; if needed, you can specify custom tasks as well as build and launch parameters through simple .json files. For general information about Open Folder, see [Develop code in Visual Studio without projects or solutions](/visualstudio/ide/develop-code-in-visual-studio-without-projects-or-solutions).
17+
In Visual Studio 2017 and later, the "Open Folder" feature enables you to open a folder of source files and immediately start coding with support for IntelliSense, browsing, refactoring, debugging, and so on. As you edit, create, move, or delete files, Visual Studio tracks the changes automatically and continuously updates its IntelliSense index. No .sln or .vcxproj files are loaded; if needed, you can specify custom tasks as well as build and launch parameters through simple .json files. This feature enables you to integrate any third-party build system into Visual Studio. For general information about Open Folder, see [Develop code in Visual Studio without projects or solutions](/visualstudio/ide/develop-code-in-visual-studio-without-projects-or-solutions).
1818

1919
## CMake and Qt
2020

@@ -28,8 +28,9 @@ To use the Visual Studio IDE with a build system or compiler toolset that is not
2828
|-|-|
2929
|CppProperties.json|Specify custom configuration information for browsing. Create this file, if needed, in your root project folder. (Not used in CMake projects.)|
3030
|tasks.vs.json|Specify custom build commands. Accessed via the **Solution Explorer** context menu item **Configure Tasks**.|
31-
|launch.vs.json|Specify command line arguments for the debugger. Accessed via the **Solution Explorer** context menu item **Debug and Launch Settings**.|`
32-
## Configure IntelliSense and browsing hints with CppProperties.json
31+
|launch.vs.json|Specify command line arguments for the debugger. Accessed via the **Solution Explorer** context menu item **Debug and Launch Settings**.|
32+
33+
## Configure code navigation with CppProperties.json
3334

3435
For IntelliSense and browsing behavior such as **Go to Definition** to work correctly, Visual Studio needs to know which compiler you are using, where the system headers are, and where any additional include files are located if they are not directly in the folder you have opened (the workspace folder). To specify a configuration, you can choose **Manage Configurations** from the dropdown in the main toolbar:
3536

@@ -147,16 +148,16 @@ This creates (or opens) the *tasks.vs.json* file in the .vs folder which Visual
147148

148149
```
149150

150-
The JSON file is placed in the *.vs* subfolder which you can see if you click on the **Show All Files** button at the top of **Solution Explorer**. You can run this task by right-clicking on the project node in **Solution Explorer** and choosing **build hello**. When the task completes you should see a new file, *hello.exe* in **Solution Explorer**.
151+
The JSON file is placed in the *.vs* subfolder which you can see if you click on the **Show All Files** button at the top of **Solution Explorer**. You can run this task by right-clicking on the root node in **Solution Explorer** and choosing **build hello**. When the task completes you should see a new file, *hello.exe* in **Solution Explorer**.
151152

152-
You can define many kinds of tasks. The following example shows a *tasks.vs.json file* that defines a single task. `taskName` defines the name that appears in the context menu. `appliesTo` defines which files the command can be performed on. The `command` property refers to the COMSPEC environment variable, which identifies the path for the console (*cmd.exe* on Windows). You can also reference environment variables that are declared in CppProperties.json or CMakeSettings.json. The `args` property specifies the command line to be invoked. The `${file}` macro retrieves the selected file in **Solution Explorer**. The following example will display the filename of the currently selected .cpp file.
153+
You can define many kinds of tasks. The following example shows a *tasks.vs.json file* that defines a single task. `taskLabel` defines the name that appears in the context menu. `appliesTo` defines which files the command can be performed on. The `command` property refers to the COMSPEC environment variable, which identifies the path for the console (*cmd.exe* on Windows). You can also reference environment variables that are declared in CppProperties.json or CMakeSettings.json. The `args` property specifies the command line to be invoked. The `${file}` macro retrieves the selected file in **Solution Explorer**. The following example will display the filename of the currently selected .cpp file.
153154

154155
```json
155156
{
156157
"version": "0.2.1",
157158
"tasks": [
158159
{
159-
"taskName": "Echo filename",
160+
"taskLabel": "Echo filename",
160161
"appliesTo": "*.cpp",
161162
"type": "command",
162163
"command": "${env.COMSPEC}",
@@ -172,7 +173,7 @@ For more information, see [Tasks.vs.json schema reference](tasks-vs-json-schema-
172173

173174
### Configure debugging parameters with launch.vs.json
174175

175-
To customize your program’s command line arguments and debugging instructions, right-click on the executable in **Solution Explorer** and select **Debug and Launch Settings**. This will open an existing *launch.vs.json* file, or if none exists, it will create a new file with a minimal task defined. First you are given a choice of what kind of debug session you want to configure. For debugging a MinGw-w64 project, we choose **C/C++ Launch for MinGGW/Cygwin (gdb)**. This creates a launch configuration for using *gdb.exe* with some educated guesses about default values. One of those default values is `MINGW_PREFIX`. You can substitute the literal path (as shown below) or you can define a `MINGW_PREFIX` property in *CppProperties.json*:
176+
To customize your program’s command line arguments and debugging instructions, right-click on the executable in **Solution Explorer** and select **Debug and Launch Settings**. This will open an existing *launch.vs.json* file, or if none exists, it will create a new file with a set of minimal launch settings. First you are given a choice of what kind of debug session you want to configure. For debugging a MinGw-w64 project, we choose **C/C++ Launch for MinGGW/Cygwin (gdb)**. This creates a launch configuration for using *gdb.exe* with some educated guesses about default values. One of those default values is `MINGW_PREFIX`. You can substitute the literal path (as shown below) or you can define a `MINGW_PREFIX` property in *CppProperties.json*:
176177

177178
```json
178179
{
@@ -198,7 +199,7 @@ To start debugging, choose the executable in the debug dropdown, then click the
198199

199200
![Launch debugger](media/launch-debugger-gdb.png)
200201

201-
You should see the **Initializing Debugger** dialog and then an external console window that is running your program.`
202+
You should see the **Initializing Debugger** dialog and then an external console window that is running your program.
202203

203204
For more information, see [launch.vs.json schema reference](launch-vs-schema-reference-cpp.md).
204205

‎docs/build/tasks-vs-json-schema-reference-cpp.md‎

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
title: "tasks.vs.json schema reference (C++)"
3-
ms.date: "08/09/2019"
3+
ms.date: "08/20/2019"
44
helpviewer_keywords: ["tasks.vs.json file [C++]"]
55
ms.assetid: abd1985e-3717-4338-9e80-869db5435175
66
---
77
# tasks.vs.json schema reference (C++)
88

9-
To tell Visual Studio how to build your source code in an an Open Folder project, add a *tasks.vs.json* file. You can define any arbitrary task here and then invoke it from the **Solution Explorer** context menu. CMake projects do not use this file because all the build commands are specified in *CMakeLists.txt*. For build systems other than CMake, *tasks.vs.json* is where you can specify build commands and invoke build scripts. For general information about using *tasks.vs.json*, see [Customize build and debug tasks for "Open Folder" development](/visualstudio/ide/customize-build-and-debug-tasks-in-visual-studio).
9+
To tell Visual Studio how to build your source code in an Open Folder project, add a *tasks.vs.json* file. You can define any arbitrary task here and then invoke it from the **Solution Explorer** context menu. CMake projects do not use this file because all the build commands are specified in *CMakeLists.txt*. For build systems other than CMake, *tasks.vs.json* is where you can specify build commands and invoke build scripts. For general information about using *tasks.vs.json*, see [Customize build and debug tasks for "Open Folder" development](/visualstudio/ide/customize-build-and-debug-tasks-in-visual-studio).
1010

1111
A task has a `type` property which may have one of four values: `default`, `launch`, `remote`, or `msbuild`. Most tasks should use `launch` unless a remote connection is required.
1212

@@ -17,7 +17,6 @@ The default properties are available on all types of tasks:
1717
||||
1818
|-|-|-|
1919
|**Property**|**Type**|**Description**|
20-
|`taskName`|string| Specifies the task label used in the user interface (Deprecated: Use `taskLabel` instead).|
2120
|`taskLabel`|string| (Required.) Specifies the task label used in the user interface.|
2221
|`appliesTo`|string| (Required.) Specifies which files the command can be performed on. The use of wildcards is supported, for example: "*", "*.cpp", "/*.txt"|
2322
|`contextType`|string| Allowed values: "custom", "build", "clean", "rebuild". Determines where in the context menu the task will appear. Defaults to "custom".|
@@ -38,7 +37,7 @@ When the task type is `launch`, these properties are available:
3837
|`workingDirectory`|string| Specifies the directory in which the command will run. Defaults to the project's current working directory.|
3938
|`customLaunchCommand`|string| Specifies a global scope customization to apply before executing the command. Useful for setting environment variables like %PATH%.|
4039
|`customLaunchCommandArgs`|string| Specifies arguments to customLaunchCommand. (Requires `customLaunchCommand`.)|
41-
|`envVars`|object| (Deprecated.) Use env.NAME syntax to specify environment variables.|
40+
`env`| Specifies a key-value list of custom environment variables. For example, "myEnv": "myVal"|
4241
|`commands`|array| Specifies a list of commands to invoke in order.|
4342

4443
### Example
@@ -104,7 +103,7 @@ The following task will appear in the context menu when you right-click on *main
104103
"version": "0.2.1",
105104
"tasks": [
106105
{
107-
"taskName": "Build",
106+
"taskLabel": "Build",
108107
"appliesTo": "main.cpp",
109108
"type": "remote",
110109
"contextType": "build",

0 commit comments

Comments
 (0)