Skip to content

Commit dfbb68a

Browse files
committed
chore: add real-world coderabbit config examples for python, rust, cpp and docs.
1 parent b02f3ee commit dfbb68a

7 files changed

+745
-0
lines changed

configs/cpp/coderabbit-cpp-base.yaml

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
early_access: false
2+
enable_free_tier: true
3+
language: en
4+
tone_instructions: ''
5+
knowledge_base:
6+
learnings:
7+
scope: auto
8+
issues:
9+
scope: auto
10+
jira:
11+
project_keys: []
12+
linear:
13+
team_keys: []
14+
chat:
15+
auto_reply: true
16+
reviews:
17+
profile: chill
18+
request_changes_workflow: false
19+
high_level_summary: true
20+
high_level_summary_placeholder: '@coderabbitai summary'
21+
poem: false
22+
review_status: true
23+
collapse_walkthrough: true
24+
path_filters: []
25+
path_instructions:
26+
- path: '**/*.hpp'
27+
instructions: >-
28+
Review the C++ code, point out issues relative to principles of clean
29+
code, expressiveness, and performance.
30+
tools:
31+
shellcheck:
32+
enabled: true
33+
ruff:
34+
enabled: true
35+
markdownlint:
36+
enabled: true
37+
github-checks:
38+
enabled: true
39+
timeout_ms: 90000
40+
languagetool:
41+
enabled: true
42+
disabled_rules:
43+
- EN_UNPAIRED_BRACKETS
44+
disabled_categories:
45+
- TYPOS
46+
- TYPOGRAPHY
47+
- CASING
48+
enabled_only: false
49+
level: default
50+
biome:
51+
enabled: true
52+
hadolint:
53+
enabled: true
54+
auto_review:
55+
enabled: true
56+
ignore_title_keywords:
57+
- WIP
58+
labels: []
59+
drafts: true
60+
base_branches:
61+
- master
+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
2+
# https://docs.coderabbit.ai/guides/configure-coderabbit/
3+
4+
language: "en-US"
5+
early_access: true
6+
reviews:
7+
profile: "chill"
8+
high_level_summary: true
9+
request_changes_workflow: false
10+
review_status: false
11+
collapse_walkthrough: false
12+
poem: false
13+
auto_review:
14+
enabled: false
15+
auto_incremental_review: false
16+
drafts: true
17+
base_branches:
18+
- master
19+
- beta
20+
- rc
21+
path_instructions:
22+
- path: "**/*"
23+
instructions: "
24+
Focus on code smells, logic errors, edge cases, missing test cases, security flaws and serious issues.
25+
Avoid commenting on minor issues such as linting, formatting and style issues.
26+
This project uses tabs instead of spaces, do not suggest usage of spaces over tabs.
27+
Are there any 'red flags' in this code that might warrant closer investigation from a security standpoint?
28+
Explain what makes them suspicious.
29+
When providing code suggestions, particularly when requested, ensure GitHub's suggestion format is used, i.e.:
30+
```suggestion
31+
<code changes>
32+
```
33+
"
34+
- path: "**/*.py"
35+
instructions: "
36+
_, pgettext, ngettext, and ngettext are defined globally, errors for this being undefined can be ignored.
37+
"
38+
- path: "**/*.md"
39+
instructions: "
40+
Focus on grammar, spelling, and punctuation.
41+
Also consider readability and clarity of contents.
42+
Ensure that changes follow the style of one sentence per line, suggest changes if this is not met.
43+
"
44+
- path: "user_docs/en/changes.md"
45+
instructions: "
46+
Ensure each change log entry references an issue or pull request number.
47+
Change log entries can also include a reference to a GitHub author.
48+
Examples of valid change log entries:
49+
* Item with sub-items (#123, @username):
50+
* sub-item
51+
* bar (#342)
52+
* Item with.
53+
Multiple lines. (#143)
54+
"
55+
tools:
56+
github-checks:
57+
enabled: true
58+
ruff:
59+
enabled: true
60+
markdownlint:
61+
# We use custom markdown syntax such as {#Anchor} for anchors.
62+
# This is not supported by markdownlint.
63+
# In future we plan to introduce markdownlint directly with custom rules. (#16453)
64+
enabled: false
65+
chat:
66+
auto_reply: true
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
language: "en"
2+
early_access: true
3+
reviews:
4+
high_level_summary: true
5+
poem: false
6+
review_status: true
7+
collapse_walkthrough: false
8+
path_filters:
9+
- "!**/.xml"
10+
path_instructions:
11+
- path: "**/.env*"
12+
instructions: |
13+
"Check that the sensitive data is not stored in the repository."
14+
- path: "frontend/api/**"
15+
instructions: |
16+
"Check the frontend API consumption against the Swagger documentation to confirm:
17+
- The frontend correctly uses the API endpoints, parameters, and handles responses as defined in Swagger.
18+
- Any discrepancies between the frontend implementation and the Swagger spec are identified and corrected."
19+
- path: "frontend/**/*.js"
20+
instructions: |
21+
"Check that the frontend code is well structured and follows the best practices of ReactJS."
22+
- path: "backend/**/*.js"
23+
instructions: |
24+
"Check that the backend code is well structured and follows the best practices of NodeJS."
25+
- path: "backend/**/*.js"
26+
instructions: |
27+
"Check the backend API implementation against the Swagger documentation to confirm:
28+
- The backend correctly implements the API endpoints, parameters, and responses as defined in Swagger.
29+
- Any discrepancies between the backend implementation and the Swagger spec are identified and corrected."
30+
auto_review:
31+
enabled: true
32+
ignore_title_keywords:
33+
- "WIP"
34+
- "DO NOT MERGE"
35+
drafts: true
36+
chat:
37+
auto_reply: true
+95
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
language: en-US
2+
tone_instructions: >-
3+
You must use a respectful, but commanding tone, as if you were impersonating an AI deity.
4+
early_access: true
5+
enable_free_tier: true
6+
reviews:
7+
profile: assertive
8+
request_changes_workflow: true
9+
high_level_summary: true
10+
high_level_summary_placeholder: '@coderabbitai summary'
11+
auto_title_placeholder: '@coderabbitai'
12+
review_status: true
13+
poem: true
14+
collapse_walkthrough: false
15+
sequence_diagrams: true
16+
path_filters: []
17+
path_instructions:
18+
- path: ".hlint.yaml"
19+
instructions: |
20+
Ignore this file
21+
- path: "*.hs"
22+
instructions: |
23+
Remember that this is a NeoHaskell file. NeoHaskell is a
24+
Haskell dialect that is inspired by Elm, therefore the
25+
Elm style and conventions should be followed. Also,
26+
Elm core libs are available, and the Haskell Prelude is
27+
ignored, as the NoImplicitPrelude extension is enabled.
28+
abort_on_close: true
29+
auto_review:
30+
enabled: true
31+
auto_incremental_review: true
32+
ignore_title_keywords: []
33+
labels: []
34+
drafts: false
35+
base_branches: []
36+
tools:
37+
shellcheck:
38+
enabled: true
39+
ruff:
40+
enabled: false
41+
markdownlint:
42+
enabled: true
43+
github-checks:
44+
enabled: true
45+
timeout_ms: 90000
46+
languagetool:
47+
enabled: true
48+
enabled_only: false
49+
level: default
50+
enabled_rules: []
51+
disabled_rules:
52+
- EN_UNPAIRED_BRACKETS
53+
enabled_categories: []
54+
disabled_categories:
55+
- TYPOS
56+
- TYPOGRAPHY
57+
- CASING
58+
biome:
59+
enabled: true
60+
hadolint:
61+
enabled: true
62+
swiftlint:
63+
enabled: true
64+
phpstan:
65+
enabled: true
66+
level: default
67+
golangci-lint:
68+
enabled: true
69+
yamllint:
70+
enabled: true
71+
gitleaks:
72+
enabled: true
73+
checkov:
74+
enabled: true
75+
detekt:
76+
enabled: true
77+
eslint:
78+
enabled: true
79+
ast-grep:
80+
packages: []
81+
rule_dirs: []
82+
util_dirs: []
83+
essential_rules: true
84+
chat:
85+
auto_reply: true
86+
knowledge_base:
87+
opt_out: false
88+
learnings:
89+
scope: global
90+
issues:
91+
scope: global
92+
jira:
93+
project_keys: []
94+
linear:
95+
team_keys: []

0 commit comments

Comments
 (0)