Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added VSCode debugging (for MvcSandbox) & code analysis support #29486

Merged
merged 8 commits into from
Apr 5, 2021
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ obj/
.packages/
.tools/
.vs/
.vscode/
node_modules/
BenchmarkDotNet.Artifacts/
.gradle/
Expand Down
25 changes: 15 additions & 10 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "PowerShell",
"request": "launch",
"name": "ps: Interactive Session",
"cwd": "${workspaceRoot}"
{
ShreyasJejurkar marked this conversation as resolved.
Show resolved Hide resolved
"name": "MvcSandbox",
"type": "coreclr",
"preLaunchTask": "MvcSandbox-build",
"request": "launch",
"program": "${workspaceFolder}/artifacts/bin/MvcSandbox/Debug/net6.0/MvcSandbox.dll",
ShreyasJejurkar marked this conversation as resolved.
Show resolved Hide resolved
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
{
"name": ".NET Core Attach",
"type": "coreclr",
"request": "attach",
"processId": "${command:pickProcess}"
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
]
}
15 changes: 15 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "MvcSandbox-build",
ShreyasJejurkar marked this conversation as resolved.
Show resolved Hide resolved
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/src/Mvc/samples/MvcSandbox/MvcSandbox.csproj"
],
"problemMatcher": "$msCompile"
}
]
}
27 changes: 27 additions & 0 deletions omnisharp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"RoslynExtensionsOptions": {
"enableAnalyzersSupport": true
},
"FormattingOptions": {
"enableEditorConfigSupport": true
},
"RenameOptions": {
"RenameInComments": true,
"RenameOverloads": true,
"RenameInStrings": true
},
"msbuild": {
"MSBuildSDKsPath": ".\\.dotnet",
"EnablePackageAutoRestore": true,
"loadProjectsOnDemand": true
},
"fileOptions": {
"systemExcludeSearchPatterns": [
"**/node_modules/**/*",
"**/bin/**/*",
"**/obj/**/*",
"**/node_modules/**/*"
],
"excludeSearchPatterns": []
}
}
3 changes: 3 additions & 0 deletions src/Antiforgery/startvscode.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@ECHO OFF

%~dp0..\..\startvscode.cmd %~dp0
22 changes: 22 additions & 0 deletions src/Azure/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "AzureAppServicesHostingStartupSample",
"type": "coreclr",
"preLaunchTask": "AzureAppServicesHostingStartupSample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/AzureAppServicesHostingStartupSample/Debug/${env:TARGET}/AzureAppServicesHostingStartupSample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
]
}
19 changes: 19 additions & 0 deletions src/Azure/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "AzureAppServicesHostingStartupSample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/AzureAppServicesHostingStartupSample/AzureAppServicesHostingStartupSample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
3 changes: 3 additions & 0 deletions src/Azure/startvscode.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@ECHO OFF

%~dp0..\..\startvscode.cmd %~dp0
3 changes: 3 additions & 0 deletions src/Caching/startvscode.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@ECHO OFF

%~dp0..\..\startvscode.cmd %~dp0
39 changes: 39 additions & 0 deletions src/Components/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "BlazorServerApp",
"type": "coreclr",
"preLaunchTask": "BlazorServerApp-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/BlazorServerApp/Debug/${env:TARGET}/BlazorServerApp.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
{
"name": "IgnitorSample",
"type": "coreclr",
"preLaunchTask": "IgnitorSample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/IgnitorSample/Debug/${env:TARGET}/IgnitorSample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
}
ShreyasJejurkar marked this conversation as resolved.
Show resolved Hide resolved
]
}
33 changes: 33 additions & 0 deletions src/Components/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "BlazorServerApp-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/Samples/BlazorServerApp/BlazorServerApp.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "IgnitorSample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/Samples/IgnitorSample/IgnitorSample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
3 changes: 3 additions & 0 deletions src/Components/startvscode.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@ECHO OFF

%~dp0..\..\startvscode.cmd %~dp0
90 changes: 90 additions & 0 deletions src/DataProtection/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "CustomEncryptorSample",
"type": "coreclr",
"preLaunchTask": "CustomEncryptorSample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/CustomEncryptorSample/Debug/${env:TARGET}/CustomEncryptorSample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
{
"name": "EntityFrameworkCoreSample",
"type": "coreclr",
"preLaunchTask": "EntityFrameworkCoreSample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/EntityFrameworkCoreSample/Debug/${env:TARGET}/EntityFrameworkCoreSample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
{
"name": "KeyManagementSample",
"type": "coreclr",
"preLaunchTask": "KeyManagementSample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/KeyManagementSample/Debug/${env:TARGET}/KeyManagementSample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
{
"name": "NonDISample",
"type": "coreclr",
"preLaunchTask": "NonDISample-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/NonDISample/Debug/${env:TARGET}/NonDISample.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
},
{
"name": "Redis",
"type": "coreclr",
"preLaunchTask": "Redis-build",
"request": "launch",
"program": "${workspaceFolder}/../../artifacts/bin/Redis/Debug/${env:TARGET}/Redis.dll",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
}
]
}
75 changes: 75 additions & 0 deletions src/DataProtection/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "CustomEncryptorSample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/CustomEncryptorSample/CustomEncryptorSample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "EntityFrameworkCoreSample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/EntityFrameworkCoreSample/EntityFrameworkCoreSample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "KeyManagementSample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/KeyManagementSample/KeyManagementSample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "NonDISample-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/NonDISample/NonDISample.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "Redis-build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/samples/Redis/Redis.csproj"
],
"problemMatcher": "$msCompile",
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
3 changes: 3 additions & 0 deletions src/DataProtection/startvscode.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@ECHO OFF

%~dp0..\..\startvscode.cmd %~dp0
7 changes: 7 additions & 0 deletions src/Mvc/.vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
ShreyasJejurkar marked this conversation as resolved.
Show resolved Hide resolved
"recommendations": [
"ms-dotnettools.csharp",
"ms-vscode.PowerShell",
"EditorConfig.EditorConfig"
]
}
Loading