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

filter diagnostics by severity level #285

Merged
merged 5 commits into from
May 25, 2023
Merged

Conversation

eatgrass
Copy link
Contributor

feat: filter diagnostics by severity level, with default keybind s

@eatgrass
Copy link
Contributor Author

I noticed we've got couples of issues and pull requests for the diagnostics filter feature, I implemented this to meet my own requirment, and also tried to keep the simplicity as much as possible.

@folke
Copy link
Owner

folke commented May 25, 2023

Thank you for this PR. Can you change it so users need to set it using the correct enums instead of a string?

So trouble.opts.severity = vim.diagnostic.severity.ERROR for example.

This will further simplify the code and is more in line on how severities are used in Neovim

@eatgrass
Copy link
Contributor Author

I changed a little bit, make the severity lsp.DiagnosticSeverity, let me know if it is ok

@folke folke merged commit b1f607f into folke:main May 25, 2023
@folke
Copy link
Owner

folke commented May 25, 2023

thanks!

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.

None yet

2 participants