-
-
Notifications
You must be signed in to change notification settings - Fork 9.9k
Expand file tree
/
Copy path.coderabbit.yaml
More file actions
111 lines (103 loc) · 3.53 KB
/
Copy path.coderabbit.yaml
File metadata and controls
111 lines (103 loc) · 3.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
#
# CodeRabbit configuration for the Strapi monorepo.
# Docs: https://docs.coderabbit.ai/guides/configure-coderabbit
language: en-US
early_access: false
reviews:
# "chill" is less noisy than "assertive"; switch to assertive if you want more nits.
profile: chill
# Don't block merges via the GitHub "request changes" review state.
request_changes_workflow: false
high_level_summary: true
high_level_summary_in_walkthrough: true
poem: false
review_status: false
collapse_walkthrough: false
# Surface a sequence diagram for non-trivial control-flow changes.
sequence_diagrams: true
changed_files_summary: true
# Conventional Commits are enforced via commitlint — keep titles aligned.
commit_status: true
auto_review:
enabled: true
# Only kick off an automatic review when the "coderabbit" label is applied.
labels:
- coderabbit
# Skip draft PRs even when labeled; mark ready for review first.
drafts: false
base_branches:
- develop
- 'releases/.*'
# Keep generated/vendored/large artifacts out of the review.
path_filters:
- '!**/node_modules/**'
- '!**/dist/**'
- '!**/build/**'
- '!**/coverage/**'
- '!**/.nx/**'
- '!**/.strapi/**'
- '!**/.cache/**'
- '!yarn.lock'
- '!**/*.snap'
- '!**/tests/e2e/data/**'
- '!**/tmp-dts-export/**'
- '!test-apps/**'
path_instructions:
- path: 'packages/**/*.{ts,tsx,js,jsx}'
instructions: >-
Follow the repo ESLint (@strapi/eslint-config / airbnb-typescript) and
Prettier rules: single quotes, semicolons, 2-space indent, trailing
commas (es5), 100-char print width, always wrap arrow params. Flag use of
`any`, unhandled promises, and missing input validation. Server-side code
receives `strapi` via dependency injection (factory pattern, e.g.
`createService(strapi)`); flag uses of `global.strapi`. New validation
should prefer Zod (validateZod/validateZodAsync); existing yup is being
migrated — don't flag it.
- path: '{packages/**,tests/**}/**/*.test.{ts,tsx,js,jsx}'
instructions: >-
Unit testing is migrating from Jest to Vitest — prefer Vitest for new
unit tests (for now). Jest still runs the bulk of the existing
unit/api/front suites. Prefer behavioural assertions over implementation
detail. Check that new logic has matching test coverage.
- path: '.github/workflows/**'
instructions: >-
Validate GitHub Actions workflows for pinned action versions, correct
permissions scoping, and shell-injection-safe use of `${{ }}` in run
steps.
- path: 'docs/**'
instructions: >-
Documentation files. Check for clarity, broken links, and consistent
terminology. Prose nits are low priority.
# Static analysis tools relevant to this repo.
tools:
eslint:
enabled: true
yamllint:
enabled: true
actionlint:
enabled: true
shellcheck:
enabled: true
markdownlint:
enabled: true
gitleaks:
enabled: true
languagetool:
enabled: true
level: default
semgrep:
enabled: true
chat:
# On a high-traffic repo, only respond when explicitly invoked
# (e.g. `@coderabbitai review` / `resolve` / `help`) rather than
# auto-replying to every comment in a thread.
auto_reply: true
knowledge_base:
opt_out: false
learnings:
scope: auto
issues:
scope: auto
pull_requests:
scope: auto