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

Add setting to control references code lens #1900

Merged
merged 2 commits into from
Aug 31, 2022

Conversation

SeeminglyScience
Copy link
Collaborator

@SeeminglyScience SeeminglyScience commented Aug 17, 2022

PR Summary

This relies on PowerShell/vscode-powershell#4139

Adds a simple setting and update handler that adds/removes the references code lens.

PR Context

This gives folks the ability to disable the high perf impact code lens without disabling all other code lenses.

@@ -22,6 +22,7 @@ internal class LanguageServerSettings
public CodeFoldingSettings CodeFolding { get; set; }
public PesterSettings Pester { get; set; }
public string Cwd { get; set; }
public bool EnableReferencesCodeLens { get; set; }
Copy link
Member

Choose a reason for hiding this comment

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

LMAO this defaulted to false which caused the unit test CanSendReferencesCodeLensRequestAsync to fail. Should we just default to true for now?

Which, being the existing default behavior, fixes the tests.
@andyleejordan andyleejordan added Issue-Enhancement A feature request (enhancement). Area-CodeLens labels Aug 30, 2022
@andyleejordan andyleejordan merged commit 62142ee into PowerShell:main Aug 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-CodeLens Issue-Enhancement A feature request (enhancement).
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants