che icon indicating copy to clipboard operation
che copied to clipboard

How can I identify that my devfile is incompatible with some editors / can only be opened with some editors?

Open nickboldt opened this issue 3 years ago • 1 comments

Summary

With the new UI in Che 7.53 that allows you to choose which editor to use when opening a sample project ...

image

I'm wondering if there's a way to specify that a given sample only supports vscode, or theia, or pycharm, or idea.

Could this be done via meta.yaml in via a new property for "editors"?

https://github.com/eclipse-che/che-devfile-registry/blob/main/devfiles/dotnet-asp.net/meta.yaml

for example, could we do something like this to prevent the sample from being loaded into theia or pycharm, with only vscode and idea supported?

displayName: "ASP.NET Core Web Application"
description: Stack for developing ASP.NET Core Web Application
tags: ["Community", "Debian", "Dotnet", "C#", "ASP.NET"]
editors: ["che-incubator/che-code/insiders", "che-incubator/che-idea/latest"]
icon: /images/dotnetcore.svg
links:
  v2: https://github.com/che-samples/aspnetcore-realworld-example-app/tree/devfilev2

Relevant information

Downstream context is that I'm wondering if we can disable a sample from being available on Theia, while supporting it on VSCode only.

See also:

  • https://issues.redhat.com/browse/CRW-2456 (dotnet doesn't work in theia, suggestion is to move to vscode and use dotnet vscode extension)
  • https://issues.redhat.com/browse/CRW-3288 (notion of removing the bad plugins from theia so the project can load w/o errors ... but also without the lang support)

nickboldt avatar Aug 25 '22 17:08 nickboldt

I don't know what you mean about 'incompatible' as all IDEs will open the project and will provide the tasks to run the project

benoitf avatar Aug 26 '22 15:08 benoitf

incompatible = "opening this with theia won't work; please use vscode instead" or incompatible = "we have tested this with vscode, so we don't know if it works in idea; therefore prevent opening it in that editor"

nickboldt avatar Oct 11 '22 15:10 nickboldt

It makes sense to omit some editors on some samples. For example it may be surprising to see IntelliJ for a .NET sample.

But coupling samples with editors is not ideal: if a new editor is added all samples meta.yaml should be reviewed, same if an editor is removed.

Instead we could use tags to decide if an editor is "compatible" with samples (for example we could specify in IntellJ definition that it's compatible with "Java", "Scala" etc...).

But today that looks like a low priority problem: it's just about samples (not a core functionality) and it's a small detail that a few will notice. Theia case should be addressed as VS Code becomes the default.

l0rd avatar Oct 11 '22 15:10 l0rd

As VSCode is now the default... should we consider this for a future release?

nickboldt avatar Nov 23 '22 17:11 nickboldt

Issues go stale after 180 days of inactivity. lifecycle/stale issues rot after an additional 7 days of inactivity and eventually close.

Mark the issue as fresh with /remove-lifecycle stale in a new comment.

If this issue is safe to close now please do so.

Moderators: Add lifecycle/frozen label to avoid stale mode.

che-bot avatar May 22 '23 00:05 che-bot