|
7 | 7 | [io-doc]: https://cpp-linter.github.io/cpp-linter-action/inputs-outputs
|
8 | 8 | [recipes-doc]: https://cpp-linter.github.io/cpp-linter-action/examples
|
9 | 9 |
|
10 |
| -[format-annotations-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/annotations-clang-format.png |
11 |
| -[tidy-annotations-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/annotations-clang-tidy.png |
12 |
| -[thread-comment-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/comment.png |
13 |
| -[step-summary-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/step-summary.png |
14 |
| -[tidy-review-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/tidy-review.png |
15 |
| -[format-review-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/format-review.png |
16 |
| -[format-suggestion-preview]: https://raw.githubusercontent.com/cpp-linter/cpp-linter-action/main/docs/images/format-suggestion.png |
17 |
| - |
18 |
| -<!--README-start--> |
| 10 | +<!-- start --> |
19 | 11 |
|
20 | 12 | # C/C++ Linter Action <sub><sup>| clang-format & clang-tidy</sup></sub>
|
21 | 13 |
|
@@ -71,49 +63,78 @@ For all explanations of our available input parameters and output variables, see
|
71 | 63 |
|
72 | 64 | See also our [example recipes][recipes-doc].
|
73 | 65 |
|
| 66 | +<!-- stop --> |
74 | 67 | ## Example
|
75 | 68 |
|
76 | 69 | ### Annotations
|
77 | 70 |
|
78 |
| -Using [`file-annotations`][file-annotations]: |
| 71 | +Using [`--file-annotations`][file-annotations]: |
79 | 72 |
|
80 | 73 | #### clang-format annotations
|
81 | 74 |
|
82 |
| -![clang-format annotations][format-annotations-preview] |
| 75 | +<picture> |
| 76 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/format-annotation-dark.png"> |
| 77 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/format-annotation-light.png"> |
| 78 | + <img alt="format-annotation-preview." src="docs/images/format-annotation-light.png"> |
| 79 | +</picture> |
83 | 80 |
|
84 | 81 | #### clang-tidy annotations
|
85 | 82 |
|
86 |
| -![clang-tidy annotations][tidy-annotations-preview] |
| 83 | +<picture> |
| 84 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/tidy-annotation-dark.png"> |
| 85 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/tidy-annotation-light.png"> |
| 86 | + <img alt="tidy-annotation-preview." src="docs/images/tidy-annotation-light.png"> |
| 87 | +</picture> |
87 | 88 |
|
88 | 89 | ### Thread Comment
|
89 | 90 |
|
90 |
| -Using [`thread-comments`][thread-comments]: |
| 91 | +Using [`--thread-comments`][thread-comments]: |
91 | 92 |
|
92 |
| -![sample thread-comment][thread-comment-preview] |
| 93 | +<picture> |
| 94 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/thread-comment-dark.png"> |
| 95 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/thread-comment-light.png"> |
| 96 | + <img alt="thread-comment-preview." src="docs/images/thread-comment-light.png"> |
| 97 | +</picture> |
93 | 98 |
|
94 | 99 | ### Step Summary
|
95 | 100 |
|
96 |
| -Using [`step-summary`][step-summary]: |
| 101 | +Using [`--step-summary`][step-summary]: |
97 | 102 |
|
98 |
| -![step summary][step-summary-preview] |
| 103 | +<picture> |
| 104 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/step-summary-dark.png"> |
| 105 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/step-summary-light.png"> |
| 106 | + <img alt="step-summary-preview." src="docs/images/step-summary-light.png"> |
| 107 | +</picture> |
99 | 108 |
|
100 | 109 | ### Pull Request Review
|
101 | 110 |
|
102 |
| -#### Only clang-tidy |
103 |
| - |
104 |
| -Using [`tidy-review`][tidy-review]: |
| 111 | +<picture> |
| 112 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/review-summary-dark.png"> |
| 113 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/review-summary-light.png"> |
| 114 | + <img alt="review-summary-preview." src="docs/images/review-summary-light.png"> |
| 115 | +</picture> |
105 | 116 |
|
106 |
| -![sample tidy-review][tidy-review-preview] |
| 117 | +#### clang-tidy suggestion |
107 | 118 |
|
108 |
| -#### Only clang-format |
| 119 | +Using [`--tidy-review`][tidy-review]: |
109 | 120 |
|
110 |
| -Using [`format-review`][format-review]: |
| 121 | +<picture> |
| 122 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/tidy-review-dark.png"> |
| 123 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/tidy-review-light.png"> |
| 124 | + <img alt="tidy-review-preview." src="docs/images/tidy-review-light.png"> |
| 125 | +</picture> |
111 | 126 |
|
112 |
| -![sample format-review][format-review-preview] |
| 127 | +#### clang-format suggestion |
113 | 128 |
|
114 |
| -![sample format-suggestion][format-suggestion-preview] |
| 129 | +Using [`--format-review`][format-review]: |
115 | 130 |
|
| 131 | +<picture> |
| 132 | + <source media="(prefers-color-scheme: dark)" srcset="docs/images/format-review-dark.png"> |
| 133 | + <source media="(prefers-color-scheme: light)" srcset="docs/images/format-review-light.png"> |
| 134 | + <img alt="format-review-preview." src="docs/images/format-review-light.png"> |
| 135 | +</picture> |
116 | 136 |
|
| 137 | +<!-- resume --> |
117 | 138 | ## Add C/C++ Linter Action badge in README
|
118 | 139 |
|
119 | 140 | You can show C/C++ Linter Action status with a badge in your repository README
|
|
0 commit comments