Skip to content

Commit ca11516

Browse files
committed
Update getting started guide and index documentation for cpp-linter
- Enhance the "Getting Started" section with detailed cpp-linter features and integration options. - Update the version of cpp-linter-hooks in the index documentation to v1.4.0 and simplify clang-tidy checks.
1 parent 77f36c4 commit ca11516

2 files changed

Lines changed: 20 additions & 12 deletions

File tree

docs/getting-started.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,28 @@
22

33
Welcome to cpp-linter! This guide will help you integrate C/C++ linting into your workflow quickly and efficiently.
44

5+
## What is cpp-linter?
6+
7+
cpp-linter connects the standard LLVM linting tools, `clang-format` and `clang-tidy`, to the places where C/C++ projects need checks: pull requests, pre-commit hooks, local scripts, and CI jobs.
8+
9+
- `clang-format` checks formatting against a named style or your `.clang-format` file.
10+
- `clang-tidy` runs static-analysis and modernization checks, usually configured by `.clang-tidy`.
11+
- cpp-linter packages those tools into integrations with consistent defaults, reporting, and failure controls.
12+
513
## Choose Your Integration
614

715
<!-- markdownlint-disable MD033 -->
816

917
Select the method that best fits your development workflow:
1018

19+
| Use case | Recommended entry point |
20+
| --- | --- |
21+
| GitHub pull request checks | [cpp-linter-action](https://cpp-linter.github.io/cpp-linter-action/) |
22+
| Local checks before commits | [cpp-linter-hooks](https://github.com/cpp-linter/cpp-linter-hooks) |
23+
| Custom scripts or CI jobs | [cpp-linter CLI](https://cpp-linter.github.io/cpp-linter/) |
24+
| High-performance local runs | [cpp-linter-rs](https://cpp-linter.github.io/cpp-linter-rs/) |
25+
26+
1127
<div class="grid cards" markdown>
1228

1329
- :material-github: **GitHub Actions**

docs/index.md

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -177,20 +177,12 @@ title: C/C++ Linting
177177
```yaml
178178
repos:
179179
- repo: https://github.com/cpp-linter/cpp-linter-hooks
180-
rev: v1.2.0 # Use the tag or commit you want
180+
rev: v1.4.0 # Use the tag or commit you want
181181
hooks:
182-
- id: clang-format
182+
- id: clang-format
183183
args: [--style=Google] # Other coding style: LLVM, GNU, Chromium, Microsoft, Mozilla, WebKit.
184-
- id: clang-tidy
185-
args:
186-
- --checks='boost-*
187-
- bugprone-*
188-
- performance-*
189-
- readability-*
190-
- portability-*
191-
- modernize-*
192-
- clang-analyzer-*
193-
- cppcoreguidelines-*'
184+
- id: clang-tidy
185+
args: [--checks=-*,bugprone-*,performance-*,readability-*]
194186
```
195187

196188
=== "Command Line"

0 commit comments

Comments
 (0)