-
Notifications
You must be signed in to change notification settings - Fork 41
feat(policy): add default and user regal config to lint #2277
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
feat(policy): add default and user regal config to lint #2277
Conversation
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
… replicated code Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
|
How does regal work today in terms of config, does it auto-detect it? Maybe we can do the same? i.e if it finds a regal config file uses it? Just thinking |
If no file provided via command line, it tries to find a default configuration in .regal and in parent directories. But everything happens in the CLI/cobra setup. I think having the command line option is enough for us, but at some point we could provide the same experience. Not important at all. |
|
Also agree the |
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
Renamed the flag to
I could add this as another config lookup step for example if no config file was provided implicitly via |
| @@ -0,0 +1,14 @@ | |||
| # Default config | |||
| rules: | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd keep the credits for the original author, i.e spacelift I think?
Signed-off-by: Sylwester Piskozub <sylwesterpiskozub@gmail.com>
This PR adds a default configuration for the Regal linter and introduces a flag to specify custom configuration.
Usage
If no config was passed or config is malformed then default config is used as fallback.
Default config:
Part of #1108