-
I'd like to have a central repo with the mega-linter configuration that I can invoke when submitting a PR in Azure DevOps to other repos. In Azure DevOps I've configured a branch policy with a build validation rule that invokes a minimal pipeline (in the repo to be checked) which in turn invokes the pipeline in the central repo. This means that the folder structure on my build agent looks like this: I have created a custom PSScriptAnalyzer rule that is stored in: The settings file is located in:
I then added these environment variables: Any thoughts why the custom rule is not included in the tests? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Please can you run MegaLinter with |
Beta Was this translation helpful? Give feedback.
-
I'd expect this command to be run in the scenario where I want the PSScriptAnalyzer default rules and my custom rules to be validated: Invoke-ScriptAnalyzer -Path .\MyScript.ps1 -CustomRulePath .\MyRule.psm1 -IncludeDefaultRules |
Beta Was this translation helpful? Give feedback.
-
In the meantime I've revised the setup and it's working now. In my original question, there's an error in the rules file. 'IncludedRules' should be 'IncludeRules'. I have my rules files in the root of my repo and that does the trick for me. |
Beta Was this translation helpful? Give feedback.
In the meantime I've revised the setup and it's working now. In my original question, there's an error in the rules file. 'IncludedRules' should be 'IncludeRules'.
I have my rules files in the root of my repo and that does the trick for me.