Me**dy 上传2KB git cppcheck pre-commit git commit时候使用pre-commit,做cppcheck.使用方法: 1. 安装软件 sudo apt-get install cppcheck 2. 本地使用githook 做pre-commit校验 拷贝到本地的工程中.git/hook/目录 这样进行提交前commit时候,如果出错,会有显示,需要大家手动解决...
fail_fast:falserepos: -repo:https://github.com/pocc/pre-commit-hooksrev:masterhooks: -id:clang-formatargs:[--style=Google]-id:clang-tidy-id:oclint-id:uncrustify-id:cppcheck-id:cpplint-id:include-what-you-use All seven linters should fail on commit with these messages. Full text is at...
...(no files to check)Skipped ruff...(no files to check)Skipped cppcheck...(no files to check)Skipped cpplint...(no files to check)Skipped codespell...
Trim Trailing Whitespace...Failed-hook id:trailing-whitespace-exit code:1-files were modified bythishook Fixing nim/dllmain.cpp Checkforadded large files...Passed Checkformerge conflicts...Passed Fix EndofFiles...
# CPP hooks - repo: https://github.com/pre-commit/mirrors-clang-format rev: v15.0.6 hooks: - id: clang-format - repo: local hooks: - id: ament_cppcheck name: ament_cppcheck description: Static code analysis of C/C++ files. stages: [commit] entry: env AMENT_CPPCHECK_ALLOW_SLOW_VE...
- hook id: cppcheck - exit code: 1 err.c:2:16: style: Unused variable: i [unusedVariable] int main(){int i;return;} ^ cpplint...Failed - hook id: cpplint - exit code: 1 Done processing err.c Total errors found: 4 err.c:0: No copyright message found. You should have ...
- id: cppcheck - id: cpplint - id: include-what-you-use args: ['-c=/home/rj/code/pre-commit-hooks/tests/uncrustify_defaults.cfg']132 changes: 0 additions & 132 deletions 132 tests/test_repo/test_integration_expected_stderr.output Load diff This file was deleted. 0...
//github.com/pocc/pre-commit-hooks rev: python hooks: - id: clang-format args: [--style=Google] - id: clang-tidy args: [-checks=clang-diagnostic-return-type] - id: oclint args: [-enable-clang-static-analyzer, -enable-global-analysis] - id: uncrustify - id: cppcheck args: [--...
fail_fast: false repos: - repo: https://github.com/pocc/pre-commit-hooks rev: master hooks: - id: clang-format args: [--style=Google] - id: clang-tidy - id: oclint - id: uncrustify - id: cppcheck - id: cpplint - id: include-what-you-use All seven linters should fail on co...