Is there a way to add custom rule options in custom rules?
For example, I want to introduce a new custom rule and then in the protolint.yaml file's rules_option section introduce new options for that particular custom rule?
@haroldlim Thank you for your interest in a custom rule.
Unfortunately, a protolint.yaml doesn't support options for custom rules at the moment. I thought the need didn't seem to be so strong because the user can pass any options in a plugin's main.go like:
https://github.com/yoheimuta/protolint/blob/4a1b88feba6c0e9e2bf826f79cf1eda4b2a7effa/_example/plugin/main.go#L13
Let me know what you think.
@yoheimuta
I think the issue with the above suggestion is that we always need to rebuild the custom plugin binary if we want to make changes?
What I was thinking is have some configurable options that we can specify in the yaml file and then the custom rule can take it in.
@haroldlim That's right. It makes sense that some users would find it useful to change the behavior without rebuilding. I was not sure about its demand actually, but if you need this nice feature, I'll add an enhancement label to this issue.
Yes. Please add enhancement label.