-
Notifications
You must be signed in to change notification settings - Fork 2
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
Extension doesn't seem to activate automatically #6
Comments
I have a couple of questions on this.
|
I believe that `[]` would mean "never activate unless explicitly used". I think that `["*"]` means "always active immediately". The former is too weak and the latter seems stronger than necessary. The current setting (activate when Rust code is used) seems right, but for some reason the codelens items don't show up. It might be something dumb like the default configuration being `false`.
…On Wed, Jun 12, 2024, at 2:23 AM, Doc Jones wrote:
I have a couple of questions on this.
1. Based upon a couple of other example extensions I've seen the activationEvents value was simply [ ].
So activationEvents: [ ] have you seen/tried this?
2. In package.json main is specified as "./dist/extension.js".
a. In the docs it is stated that "main" in package.json would be set to "./out/extension.js" for extensions in dev and "./dist/extension.js" for production. Is this extension in production? Does it matter?
—
Reply to this email directly, view it on GitHub <#6 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AABF4ZRDUIELZHCAEA5ZTTDZG7SP7AVCNFSM6AAAAABJA256RCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRSGE4TOMJTGI>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
I wonder if it is a timing issue, I haven't had to run "IntoRust: Enable codelens". After opening the "Extension Development Host" window (is that what you're doing?), it seems to depend on how/when the CodeLensProvider.provideCodeLenses is triggered, when diagnostics are available, etc. Putting focus on the window usually triggers it, or editing the file. |
Yes, I see the difference between [] and ["*"]. I'm still catching up on the extensions documentation. |
Maybe I'm just impatient
…On Wed, Jun 12, 2024, at 9:54 AM, Kari Wilhelm wrote:
I wonder if it is a timing issue, I haven't had to run "IntoRust: Enable codelens". After opening the "Extension Development Host" window (is that what you're doing?), it seems to depend on how/when the CodeLensProvider.provideCodeLenses is triggered, when diagnostics are available, etc. Putting focus on the window usually triggers it, or editing the file.
—
Reply to this email directly, view it on GitHub <#6 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AABF4ZT7TASUI7HKCKXH3EDZHBHLDAVCNFSM6AAAAABJA256RCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRTGA3TIMBVGE>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
I'm not sure why but I seem to have to run "IntoRust: Enable codelens" from the command palette to get things to show up. I haven't tested whether e.g. using
activationEvents: ["*"]
instead of the current "active on rust" would help:https://github.com/nikomatsakis/intorust.vscode/blob/ffff983688652133fe4a5fc80221fba683a6e6f5/package.json#L18-L20
...but it's worth a try. That might be a clue. If not that, well, I don't know, something!
The text was updated successfully, but these errors were encountered: