Skip to content

FW: Add a linter #239

Description

@Ruben-Lohberg

We should integrate a linter into our project.

  • Catch obvious bugs through static code analysis (cppcheck)
  • Enforce coding conventions such as a maximum nesting depth (article)
    • A linter can be configured to ignore legacy code and only check for formatting in the changed lines of a commit

Linters can be run both locally during development and in a pipeline on pull requests. They can create well formatted linting reports which a pipeline can paste into a pull request.

https://megalinter.io/latest/ is a very popular option. It comes with an installer to easily create a pipeline in minutes. Already contains cppcheck

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions