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

linter: Add WithCustomRulesFromFS SDK option #503

Merged
merged 1 commit into from
Nov 29, 2023
Merged

linter: Add WithCustomRulesFromFS SDK option #503

merged 1 commit into from
Nov 29, 2023

Conversation

charlieegan3
Copy link
Member

Fixes #492

@@ -272,6 +273,29 @@ func TestLintWithCustomRule(t *testing.T) {
}
}

//go:embed testdata/*
Copy link
Member

Choose a reason for hiding this comment

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

👏 the quickest way to get an fs.Fs.

Copy link
Member Author

Choose a reason for hiding this comment

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

Taking shortcuts 😉

Related to #492

Signed-off-by: Charlie Egan <charlie@styra.com>
@charlieegan3
Copy link
Member Author

@jamietanna, would you be able to take a look and see if this works for your use case?

Copy link
Contributor

@jamietanna jamietanna left a comment

Choose a reason for hiding this comment

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

Can confirm that I've been able to get this working 🚀

@anderseknert anderseknert merged commit f7dca35 into main Nov 29, 2023
3 checks passed
@anderseknert anderseknert deleted the embed-fs branch November 29, 2023 14:13
@charlieegan3
Copy link
Member Author

🚂 that's great!

srenatus pushed a commit to srenatus/regal that referenced this pull request Oct 1, 2024
Related to StyraInc#492

Signed-off-by: Charlie Egan <charlie@styra.com>
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.

Allow custom rules to be provided with raw contents / via an fs.FS
4 participants