Skip to content

Add clang-tidy editor.codeActionsOnSave entry point #12684

Closed as not planned
Closed as not planned
@thernstig

Description

@thernstig

Feature Request

The proper way for extensions to add linting fixes (not formatting fixes) is to add entries like this in the VS Code config:

  "editor.codeActionsOnSave": {
    "source.organizeImports": "always",
    "source.fixAll.eslint": "always",
    "source.fixAll.markdownlint": "always",
    "source.fixAll.stylelint": "always"
  },

It would be nice if this extension could add a source.fixAll.clangTidy that would then automatically fix all fixable problems on save.

References

https://stackoverflow.com/a/61051832/1853417
https://code.visualstudio.com/api/references/vscode-api (search for CodeActionProvider)
https://code.visualstudio.com/updates/v1_83#_code-actions-on-save-and-auto-save

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature: Code AnalysisRelated to integration with clang-tidy, cppcheck, cl.exe /analyze, etc.Language ServiceenhancementImprovement to an existing featurehelp wantedCan be fixed in the public (open source) repo.more votes neededIssues that have been postponed until more community members upvote it

    Projects

    Status

    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions