-
Notifications
You must be signed in to change notification settings - Fork 30.6k
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
Add "Copy as..." from debug extensions #188604
Comments
An extension can register a command on the variables tree context menu, which has the ID |
Yes, looks good. I'm digging around to get the right types, but I think I can work with this. I've spoke too soon. First I register the menu, this works:
I then register the command: context.subscriptions.push(
vscode.commands.registerCommand('php.debug.testctx', async (arg: IVariablesContext, p2:any, p3:any) => {
await vscode.debug.activeDebugSession?.customRequest('evaluate', <DebugProtocol.EvaluateArguments>{
context: 'clipboard-wtf',
expression: arg.variable.evaluateName,
// frameId: vscode.debug.stackFrameFocus
}) I used this code to model the command
The Am I going about this the right way? Thanks! |
Hey @roblourens, this issue might need further attention. @zobo, you can help us out by closing this issue if the problem no longer exists, or adding more information. |
Hi @VSCodeTriageBot ! ;) Not sure if there was any API change, but the last time I checked there were some public API interfaces missing that prevented me from implementing this desired feature. I have not worked on it in a while and not sure if I will implement it like this - however the referenced task that also deals with the underlying issue will hopefully be moved forward. In this light the current task could potentially be closed as a duplicate or left open as "depends on". |
Nevertheless it would be great to get a definitive reply if I am correctly interpreting the API code. |
Yeah, that is not exposed right now. I guess it should be on that context object, or exposed as in #63943 |
This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 20 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation. Happy Coding! |
This feature request has not yet received the 20 community upvotes it takes to make to our backlog. 10 days to go. To learn more about how we handle feature requests, please see our documentation. Happy Coding! |
🙁 In the last 60 days, this feature request has received less than 20 community upvotes and we closed it. Still a big Thank You to you for taking the time to create this issue! To learn more about how we handle feature requests, please see our documentation. Happy Coding! |
Hi all!
I was wondering if there were a way for a debugger extension to influence the debugger windows. In reference to this issue xdebug/vscode-php-debug#400 I was wondering if the PHP Debug extension could somehow register additional context options when a user right clicks on a variable to copy its value. I'd like to add context menu items like "Copy Value as JSON" and "Copy Value as var_export" and then have these commands send a DAP
evaluateRequest
with a specific, custom, context instead ofclipboard
. Likeclipboard-json
...This could probably be achieved in a declarative way through the manifest (very issue specific) or some hooks in the extension code (more general approach).
Thanks!
The text was updated successfully, but these errors were encountered: