lsp: Add code action and command to ignore rule#1777
Merged
charlieegan3 merged 4 commits intoopen-policy-agent:mainfrom Nov 20, 2025
Merged
lsp: Add code action and command to ignore rule#1777charlieegan3 merged 4 commits intoopen-policy-agent:mainfrom
charlieegan3 merged 4 commits intoopen-policy-agent:mainfrom
Conversation
274b4ce to
770b610
Compare
Fixes open-policy-agent#622 Signed-off-by: Charlie Egan <charlie_egan@apple.com>
770b610 to
361d9ce
Compare
anderseknert
approved these changes
Nov 19, 2025
Member
anderseknert
left a comment
There was a problem hiding this comment.
Thanks! Just one question.
|
|
||
| var currentContent string | ||
|
|
||
| if _, err := os.Stat(configPath); err == nil { |
Member
There was a problem hiding this comment.
If the stat fails here, we'll just proceed as normal? That doesn't seem right. even if it is unlikely to fail. I'd just call os.ReadFile directly.
| ) | ||
|
|
||
| // SetKey sets a key at the given path to the specified value. | ||
| // Comments are preserved, but indentation is always 2. |
Member
There was a problem hiding this comment.
As God intended for YAML.
Did you try this on a more "complex" configuration file, like our own?
Contributor
Author
There was a problem hiding this comment.
Screen.Recording.2025-11-19.at.14.43.31.mov
it seems to work ok from what I can tell.
| style: | ||
| prefer-snake-case: | ||
| level: error # Important rule | ||
| # Additional configuration |
Signed-off-by: Charlie Egan <charlie_egan@apple.com>
Signed-off-by: Charlie Egan <charlie_egan@apple.com>
Signed-off-by: Charlie Egan <charlie_egan@apple.com>
auto-merge was automatically disabled
November 20, 2025 15:23
Pull request was closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #622
Screen.Recording.2025-11-18.at.14.46.40.mov