-
-
Notifications
You must be signed in to change notification settings - Fork 242
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
TEMPLATES/mega-linter.yml: DRY the ifs #2957
Conversation
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.
@rasa it seems an interesting PR :)
Did you test it and do you confirm the behavior is exactly the same ? I wouldn't like to take the risk of regressions ^^
This pull request has been automatically marked as stale because it has not had recent activity. If you think this pull request should stay open, please remove the |
I have tested it locally, and both code paths work as intended. Unfortunately, I can't share logs as they are on private repos. But since it's just DRYing the code, feel free to reject. I won't take offense. |
@rasa I love DRY rules, so if you tested it let's trust you and see how it goes on own MegaLinter :) But to do that, please can you also update own MegaLinter workflows ?
|
@rasa seems good but you need to merge main in your branch to solve conflicts before i can validate :) |
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.
Wonderful:)
Many thanks for your contribution @rasa 🎉
@rasa please can you also make a PR to update https://github.com/oxsecurity/megalinter/blob/main/mega-linter-runner/generators/mega-linter/templates/mega-linter.yml ? This is the file that is used by the installer ^^ |
Proposed Changes
This simplifies
TEMPLATES/mega-linter.yml
by moving common code to its own step. This also can help with debugging, as these variables now show up in the logs. Accept or reject as you see fit.Readiness Checklist
Edit: I've had success running this PR in private repos.
Author/Contributor