Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is the launch.json file in VS Code?

The launch.json file should be inside the .vscode folder but it is not present there.

How to get this file so that I can modify the configurations?

like image 467
Amaan Zafar Avatar asked May 12 '21 00:05

Amaan Zafar


People also ask

Where is the launch json file?

json file located in a . vscode folder in your workspace (project root folder) or in your user settings or workspace settings. To create a launch.

What is a launch json file in VS Code?

A launch. json file is used to configure the debugger in Visual Studio Code. Visual Studio Code generates a launch. json (under a . vscode folder in your project) with almost all of the required information.

Where is the code json in Visual Studio settings?

You can open the settings. json file with the Preferences: Open Settings (JSON) command in the Command Palette (Ctrl+Shift+P). Once the file is open in an editor, delete everything between the two curly braces {} , save the file, and VS Code will go back to using the default values.


2 Answers

As described in the Launch Configurations section of the VS Code docs:

VS Code keeps debugging configuration information in a launch.json file located in a .vscode folder in your workspace (project root folder) or in your user settings or workspace settings.

To create a launch.json file, click the create a launch.json file link in the Run start view.

As of VS Code 1.56:

VS Code screenshot for create launch.json file link

Once that's created, it should now be available under your workspace's .vscode folder.

VS Code screenshot of File Explorer with launch.json file

like image 113
Gino Mempin Avatar answered Sep 18 '22 17:09

Gino Mempin


Click on the debug side bar to open the debugging options. Then either the cog icon at the top, or the create a launch.json file link below the big blue button. If the launch.json file is present, it will open it otherwise it will generate one.

like image 45
Amaan Zafar Avatar answered Sep 20 '22 17:09

Amaan Zafar