Skip to content

Remove quarkus-properties language and collect document selectors from extensions#8

Merged
xorye merged 1 commit intoredhat-developer:masterfrom
xorye:3_remove_quarkus
Jul 28, 2020
Merged

Remove quarkus-properties language and collect document selectors from extensions#8
xorye merged 1 commit intoredhat-developer:masterfrom
xorye:3_remove_quarkus

Conversation

@xorye
Copy link
Copy Markdown

@xorye xorye commented Jul 20, 2020

Fixes #3

Signed-off-by: David Kwon dakwon@redhat.com

@xorye
Copy link
Copy Markdown
Author

xorye commented Jul 20, 2020

To test this PR:

  • package this PR into a vsix and install
  • checkout Define Quarkus document selector and TextMate grammar vscode-quarkus#294 and start vscode-quarkus (either start it from sources or install it as a vsix, it doesn't matter)
  • open a Quarkus application.properties file (make sure that the languageId is quarkus-properties) and invoke completion. Since the file's language is quarkus-properties, the textdocument/completion request should be sent to the MP language server, and completion items should be returned.

Copy link
Copy Markdown
Collaborator

@rzgry rzgry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at the schema It looks like this provides a vscode extension the ability to provide a single document selector. Would their ever be a use-case where an extension would need to provide multiple document selectors?

Comment thread schemas/package.schema.json Outdated
@xorye xorye marked this pull request as draft July 21, 2020 14:37
@xorye
Copy link
Copy Markdown
Author

xorye commented Jul 21, 2020

Looking at the schema It looks like this provides a vscode extension the ability to provide a single document selector. Would their ever be a use-case where an extension would need to provide multiple document selectors?

@rzgry thanks for the review, I will make changes.

Also, to be consistent with https://github.com/microsoft/vscode-languageserver-node/blob/3eddc56d9491b6f97c5e82242a3a14421d42bea1/protocol/src/common/protocol.ts#L74, I will add pattern as a possible field.

@xorye xorye marked this pull request as ready for review July 22, 2020 18:49
…m extensions

Signed-off-by: David Kwon <dakwon@redhat.com>
@xorye xorye changed the title Collect document selectors from extensions Remove quarkus-properties language and collect document selectors from extensions Jul 22, 2020
@xorye
Copy link
Copy Markdown
Author

xorye commented Jul 28, 2020

@rzgry @datho7561 if there aren't any more changes to be made, I'd like to merge this soon. Please let me know, thanks!

@xorye
Copy link
Copy Markdown
Author

xorye commented Jul 28, 2020

For some reason, the client/registerCapability request for range formatting has quarkus-properties appearing twice:

MicroProfile Tools server trace:

[Trace - 11:16:26 a.m.] Received request 'client/registerCapability - (8)'.
Params: {
    "registrations": [
        {
            "id": "61e7b5ba-a567-4415-8817-70e18fed36a9",
            "method": "textDocument/rangeFormatting",
            "registerOptions": {
                "documentSelector": [
                    {
                        "language": "microprofile-properties"
                    },
                    {
                        "language": "quarkus-properties"
                    },
                    {
                        "language": "quarkus-properties"
                    }
                ]
            }
        }
    ]
}

I don't think its caused by this PR though. I'm investigating.

@xorye
Copy link
Copy Markdown
Author

xorye commented Jul 28, 2020

It's not caused by this PR, this still happens in the 1.6.0 vscode-quarkus release. I made an issue about this: redhat-developer/vscode-quarkus#296

@xorye xorye merged commit 677c1ba into redhat-developer:master Jul 28, 2020
@angelozerr angelozerr added the enhancement New feature or request label Sep 11, 2020
@angelozerr angelozerr added this to the 0.1.0 milestone Sep 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove quarkus-properties language

5 participants