microsoft / vscode-docker

Docker Extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker
Other
1.18k stars 508 forks source link

[Bug Report/potential feature request] Extension not respecting `editor.defaultFormatter` key #4220

Closed AbstractUmbra closed 5 months ago

AbstractUmbra commented 5 months ago

I have both this extension and the RedHat YAML extension installed. This does seem to create a conflict with which extension will perform formatting on dockercompose language files.

The resulting bug is that no formatting is done and you're presented with a warning window of "There is no formatter for 'dockercompose' files installed.".

As such I tried to override the formatter using the following config key in my global settings.json:-

    "[dockercompose]": {
        "editor.defaultFormatter": "redhat.vscode-yaml",
    }

This key however seems to be ignored by the extension, or some other interaction occurs resulting in the same warning window popping up.

My issue is - is this an intended ignored key, or could functionality be introduced to respect this key?

AbstractUmbra commented 5 months ago

A related issue exists on the YAML repo side of things:- redhat-developer/vscode-yaml#1000

bwateratmsft commented 5 months ago

Thanks, @LisonFan originally opened https://github.com/microsoft/vscode-docker/issues/4196 here so I'll dupe this to that.