File tree 1 file changed +11
-2
lines changed
1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -66,6 +66,12 @@ export async function startDebugSession(ctx: Ctx, runnable: ra.Runnable): Promis
66
66
return vscode . debug . startDebugging ( undefined , debugConfig ) ;
67
67
}
68
68
69
+ function createCommandLink ( extensionId : string ) : string {
70
+ // do not remove the second quotes inside
71
+ // encodeURIComponent or it won't work
72
+ return `extension.open?${ encodeURIComponent ( `"${ extensionId } "` ) } ` ;
73
+ }
74
+
69
75
async function getDebugConfiguration (
70
76
ctx : Ctx ,
71
77
runnable : ra . Runnable ,
@@ -90,9 +96,12 @@ async function getDebugConfiguration(
90
96
}
91
97
92
98
if ( ! debugEngine ) {
99
+ const commandCodeLLDB : string = createCommandLink ( "vadimcn.vscode-lldb" ) ;
100
+ const commandCpp : string = createCommandLink ( "ms-vscode.cpptools" ) ;
101
+
93
102
await vscode . window . showErrorMessage (
94
- `Install [CodeLLDB](https://marketplace.visualstudio.com/items?itemName=vadimcn.vscode-lldb )` +
95
- ` or [MS C++ tools](https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools ) extension for debugging.` ,
103
+ `Install [CodeLLDB](command: ${ commandCodeLLDB } "Open CodeLLDB" )` +
104
+ ` or [C/C++](command: ${ commandCpp } "Open C/C++" ) extension for debugging.` ,
96
105
) ;
97
106
return ;
98
107
}
You can’t perform that action at this time.
0 commit comments