vscode icon indicating copy to clipboard operation
vscode copied to clipboard

Enable quick fixes in the scm input

Open mjbvz opened this issue 3 years ago • 2 comments

Fixes #159940

Screen Shot 2022-09-02 at 11 28 51 AM

mjbvz avatar Sep 02 '22 18:09 mjbvz

Thanks @mjbvz! This does fix part of the problem as now the quick fix menu appears but for some reason picking one of the available fixes does nothing - as in the value in the commit input does not get replaced. Not sure if you looked into that but if you do not know from the top of your head what the issue is, I can pick this up and further investigate.

lszomoru avatar Sep 05 '22 10:09 lszomoru

@lszomoru Yes, I think there are two issues here:

  1. For code actions that use commands, many existing extensions don't know how to work with the scm input. This causes the command to fail

  2. For code actions that use a WorkspaceEdit, it's currently not possible to edit the scm input box. This is because the bulk edit service cannot resolve the text model used by the source control input: https://github.com/microsoft/vscode/blob/19631493d8b6afb46eab0791fae995ebe4668456/src/vs/workbench/contrib/bulkEdit/browser/bulkTextEdits.ts#L231

For point 2, would it make sense to register the scm input model as a normal text model?

mjbvz avatar Sep 07 '22 21:09 mjbvz

@mjbvz, thanks for these findings. Let me chat with couple of folks and see what would be the best way to move this forward.

lszomoru avatar Sep 23 '22 15:09 lszomoru

Superseded by #176699

mjbvz avatar Mar 09 '23 22:03 mjbvz