-
Notifications
You must be signed in to change notification settings - Fork 0
docs: add instructions for adding new compliance checks in README #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Included detailed steps for creating a new compliance check class, registering it, defining configuration types, updating the JSON schema, and adding tests. - Enhanced documentation to facilitate the onboarding of new contributors and improve project extensibility.
📊 Build ReportBundle Size: 1.15 KB Details
Generated for commit f6a6a90 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2 issues found across 1 file
Prompt for AI agents (all 2 issues)
Understand the root cause of the following 2 issues and fix them.
<file name="README.md">
<violation number="1" location="README.md:302">
Incorrect type name in docs: use Defaults (not ComplianceDefaults) to match src/config/types.ts and ComplianceConfig.defaults.</violation>
<violation number="2" location="README.md:308">
Clarify JSON Schema update: also add the new key under rules.apply properties, not just defaults, since additionalProperties is false in both sections.</violation>
</file>
React with 👍 or 👎 to teach cubic. Mention @cubic-dev-ai to give feedback, ask questions, or re-run the review.
| } | ||
| ``` | ||
|
|
||
| 4. **Update the JSON Schema** in `compliance-schema.json`: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Clarify JSON Schema update: also add the new key under rules.apply properties, not just defaults, since additionalProperties is false in both sections.
Prompt for AI agents
Address the following comment on README.md at line 308:
<comment>Clarify JSON Schema update: also add the new key under rules.apply properties, not just defaults, since additionalProperties is false in both sections.</comment>
<file context>
@@ -239,6 +239,99 @@ npm run build
+ }
+ ```
+
+4. **Update the JSON Schema** in `compliance-schema.json`:
+ - Add your check configuration to the `defaults` properties
+ - Ensure proper validation rules are defined
</file context>
| // Define your configuration structure | ||
| } | ||
|
|
||
| export interface ComplianceDefaults { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Incorrect type name in docs: use Defaults (not ComplianceDefaults) to match src/config/types.ts and ComplianceConfig.defaults.
Prompt for AI agents
Address the following comment on README.md at line 302:
<comment>Incorrect type name in docs: use Defaults (not ComplianceDefaults) to match src/config/types.ts and ComplianceConfig.defaults.</comment>
<file context>
@@ -239,6 +239,99 @@ npm run build
+ // Define your configuration structure
+ }
+
+ export interface ComplianceDefaults {
+ // ... existing configs
+ your_config_key?: YourCheckConfig;
</file context>
| export interface ComplianceDefaults { | |
| export interface Defaults { |
Summary by cubic
Added step-by-step instructions to the README for adding a new compliance check to make contributor onboarding faster.
Covers creating the check class, registering it, defining config types, updating the JSON Schema, adding tests, and updating the Available Checks and sample YAML.