oxsecurity / megalinter

🦙 MegaLinter analyzes 50 languages, 22 formats, 21 tooling formats, excessive copy-pastes, spelling mistakes and security issues in your repository sources with a GitHub Action, other CI tools or locally.
https://megalinter.io
GNU Affero General Public License v3.0
1.9k stars 231 forks source link

Want to have control on the version of linter that is being used #4014

Open guptajag opened 1 week ago

guptajag commented 1 week ago

Is your feature request related to a problem? It is important to control the specific version of CPP_CLANG_FORMAT used during the linting process. For instance, the current version supported by Mega-Linter is 17.0.6**:

image

However, the project requires Clang 20.0.0

Describe the solution you'd like There should be an option in the .mega-linter.yml file to specify the desired version of the linter, such as:

ENABLE_LINTERS:
  - CPP_CLANG_FORMAT == 20.0.0

or

ENABLE_LINTERS:
  - CPP_CLANG_FORMAT =< 17.0.6

This feature would dynamically create or update the necessary Mega-Linter container during runtime to ensure the specified version is used.

Describe alternatives you've considered Currently exploring solutions but have not found any suitable alternatives to manually controlling the Clang format version.

echoix commented 1 week ago

Clang 19.1 (the first real release) was released yesterday... clang 20 would be something very custom and highly specific

nvuillam commented 1 week ago

@guptajag linters are installed during the build of MegaLinter, so if you need to override their version you can re-install the version you need using PRE_COMMANDS