Skip to content
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

Enable the "Restart LSP" command only if a LSP is configured #345

Conversation

vogelsgesang
Copy link
Collaborator

@vogelsgesang vogelsgesang commented Feb 27, 2024

This commit hides the "Restart LSP" command from the Command Palette if the LSP is disabled. Otherwise, trying to use the "Restart LSP" command without any LSP being configured leads to a user-visible error.

As part of this, I also renamed vscodeBazelHaveBazelWorkspace to bazel.haveWorkspace such that the context variables all share a common bazel.* prefix.

BEGIN_COMMIT_OVERRIDE
fix: Enable the "Restart LSP" command only if the language server is enabled (#345)
END_COMMIT_OVERRIDE

This commit hides the "Restart LSP" command from the Command Palette if
the LSP is disabled. Otherwise, trying to use the "Restart LSP" command
without any LSP being configured leads to a user-visible error.

As part of this, I also renamed `vscodeBazelHaveBazelWorkspace` to
`bazel.haveWorkspace` such that the context variables all share a common
`bazel.*` prefix.
@vogelsgesang
Copy link
Collaborator Author

Thanks for your review, @cameron-martin !

It seems I don't have the necessary permissions to merge this PR myself. What is the usual workflow in this repository? Can you merge this on my behalf?

@cameron-martin cameron-martin enabled auto-merge (squash) February 27, 2024 17:42
@cameron-martin cameron-martin merged commit 15793a4 into bazel-contrib:master Feb 27, 2024
4 checks passed
@vogelsgesang vogelsgesang deleted the avogelsgesang-hide-lsp-restart branch March 26, 2024 02:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants