chore: add Greptile and GitGuardian configs#49
Conversation
Both tools are free for public OSS repos under MIT/Apache/GPL — Greptile
via the OSS Perks program, GitGuardian via the public-repo free tier.
Cubic is also free for public repos but is configured purely through
the GitHub App, with no in-repo file needed.
greptile.json
- strictness 2 + commentTypes [logic, syntax] (matches CodeRabbit's
"bugs and security over style" stance)
- ignoreKeywords: bump version / release / chore: bump / chore(release)
/ chore(deps) so dependabot and release PRs don't get noisy reviews
- disabledLabels: release, skip-review (manual escape hatch)
- ignorePatterns: lockfiles, node_modules, *.DS_Store, binary doc assets
- instructions: project base prompt — Gemini CLI extension, not a
typical app; common false-positive flags called out
- customContext.rules: per-path guidance mirroring path_instructions
in .coderabbit.yaml — agents (tool allowlist), commands (egc-
prefix), skills, hooks, scripts, rules, docs
- customContext.files: pins .gemini/styleguide.md and the gemini-tools
lib as authoritative references
.gitguardian.yaml
- secret.ignored_paths: lockfiles, node_modules, binary doc assets,
plus tests/lint/fixtures/** and tests/ci/** (the latter embeds
`${{ github.event.pull_request.head.sha }}` strings as hostile
workflow fixtures, which entropy-style detectors can misfire on)
- ignored_detectors: 'Generic High Entropy Secret' to suppress noise
from documentation examples and curl snippets
Lint clean / 187 tests pass.
Action items for the maintainer (not in-repo):
- Install Cubic GitHub App: https://github.com/apps/cubic-dev-ai
- Apply for Greptile OSS plan: https://www.ossperks.com/programs/greptile
- GitGuardian app should already pick up .gitguardian.yaml automatically
once the org is on the free OSS tier
WalkthroughThis PR introduces two new configuration files: GitGuardian setup for secret detection with customized exclusions and disabled entropy detector, and Greptile configuration for AI-assisted code review with governance rules, scanning controls, and tool validation guidance. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested labels
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.gitguardian.yaml:
- Around line 32-33: Remove the global disabling of the "Generic High Entropy
Secret" detector under the ignored_detectors key and instead scope exceptions to
known test/example files: delete the entry '- 'Generic High Entropy Secret''
from ignored_detectors and add path-scoped ignores or inline allowlists for the
specific fixtures/docs that contain fake secrets (use the config's per-path
ignore rules or inline allowlisting mechanism) so the detector remains active
for the rest of the repo.
In `@greptile.json`:
- Around line 38-39: The rule text and its "scope" are mismatched: update
greptile.json so the ban on console.log applies only to hook scripts (e.g.,
change "scope" to ["hooks/**/*.js"] or split into two rules — one rule with the
Node.js guidance scoped to ["scripts/**/*.js","tests/**/*.js"] and a separate
rule whose "rule" string specifically forbids console.log and whose "scope" is
["hooks/**/*.js"]); ensure you edit the "rule" and corresponding "scope" entries
(the JSON keys "rule" and "scope") so each rule's text matches its scope.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: d3cefd1c-64a5-4d05-aed9-0712da85f677
📒 Files selected for processing (2)
.gitguardian.yamlgreptile.json
Greptile SummaryThis PR adds
Confidence Score: 4/5Safe to merge with one minor discrepancy to resolve or document. Both config files are structurally valid and well-reasoned. The only finding is a P2 discrepancy between the PR description's claim about
Important Files Changed
Reviews (3): Last reviewed commit: "fix: address review feedback on PR #49" | Re-trigger Greptile |
Greptile SummaryThis PR adds two bot configuration files — Confidence Score: 5/5Safe to merge — both config files are well-structured with no application logic changes; only minor P2 findings remain. All findings are P2 (style/suggestion level): a shell-safety-directive mismatch between greptile.json and the styleguide that may produce noisy bot comments, and a broad directory exclusion in .gitguardian.yaml that is a known trade-off documented in the PR. Neither blocks correct behavior of the application or CI. The greptile.json shell rule should be aligned with .gemini/styleguide.md before the next non-release PR to avoid spurious bot comments on compliant scripts. Important Files Changed
|
There was a problem hiding this comment.
4 issues found across 2 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name=".gitguardian.yaml">
<violation number="1" location=".gitguardian.yaml:32">
P1: Disabling `Generic High Entropy Secret` globally weakens secret scanning coverage and can hide real leaked credentials. Prefer path-scoped ignores for noisy fixtures instead of turning off this detector for the whole repository.</violation>
</file>
<file name="greptile.json">
<violation number="1" location="greptile.json:8">
P2: Section config fields use booleans, but Greptile expects objects for `summarySection`/`confidenceScoreSection`/`sequenceDiagramSection`.</violation>
<violation number="2" location="greptile.json:11">
P2: The bare keyword `"release"` in `ignoreKeywords` will cause Greptile to skip review on **any** PR whose title or description contains the word "release" as a substring — e.g., "Add release notes", "Document feature release process", or "Fix memory release bug". The other entries (`chore: bump`, `chore(release)`, `chore(deps)`) are specific enough. Consider removing the bare `release` or replacing it with a more specific pattern like `chore: release` to avoid unintended review suppression.</violation>
<violation number="3" location="greptile.json:39">
P2: The `"No console.log in hook scripts"` directive is hook-specific, but the `scope` includes `tests/**/*.js` where `console.log` is perfectly normal. This will generate false positive comments on test files. Narrow the scope to hook-related paths only, or split into separate rules.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review, or fix all with cubic.
CodeRabbit + cubic + Greptile flagged five issues; all valid.
greptile.json
- section fields now use the documented object shape
{ included, collapsible, defaultOpen } instead of bare booleans
(cubic P2; verified against
greptile.com/docs/code-review-bot/greptile-json)
- removed the bare "release" keyword from ignoreKeywords; was too
broad — would have skipped review on PRs titled "Add release
notes", "Document release process", "Fix memory release bug", etc.
Replaced with the more specific `chore: release`. Other entries
(chore: bump, chore(release), chore(deps)) keep the dependabot/
release-PR coverage. (cubic P2, Greptile P2)
- split the Node.js general-style rule from the hook-specific
"no console.log" directive. The original rule scoped console.log
enforcement to scripts/**/*.js + tests/**/*.js, which would
flag every test file (tests legitimately use console.log to
report results). The no-console-log clause now lives on the
hooks-scoped rule. (CodeRabbit nitpick, cubic P2)
- aligned the shell-script rule with .gemini/styleguide.md: the
styleguide mandates `set -e`, the rule had `set -euo pipefail`.
Greptile would have flagged styleguide-compliant scripts as
non-compliant. (Greptile P2)
.gitguardian.yaml
- removed the global `ignored_detectors: ['Generic High Entropy
Secret']` entry. Disabling the detector repo-wide could mask a
real leaked secret outside the noisy paths. (CodeRabbit major,
cubic P1)
- replaced with two additional path-scoped entries that target the
actual sources of false positives:
rules/**/security.md — documentation examples (e.g. the
fake `sk-proj-xxxxx` placeholder)
**/SKILL.md — skill docs that may show fake API
tokens for illustration
The detector remains active for the rest of the tree.
Lint clean / 187 tests pass.
Summary
Adds in-repo configuration for two of the three review/security bots in active use on the upstream
everything-claude-code. All three are free for our case (MIT-licensed public repo).greptile.json(this PR).gitguardian.yaml(this PR)greptile.jsonMirrors the intent of
.coderabbit.yaml:strictness: 2+commentTypes: [logic, syntax]— bugs and security over styleignoreKeywords— release PRs and dependabot PRs are skippeddisabledLabels: ["release", "skip-review"]— manual escape hatchinstructions— project base prompt that frames the repo as a Gemini CLI extension and lists the common false-positive patterns to ignore (emoji in markdown, long TOML prompt fields,~/.gemini/paths in skills)customContext.rules— per-path guidance foragents/,commands/,skills/,hooks/,scripts/,rules/,docs/(mirrorspath_instructionsfrom CodeRabbit, including the agent tool allowlist)customContext.files— pins.gemini/styleguide.mdandscripts/lib/gemini-tools.jsas the authoritative references the bot should consult.gitguardian.yamlDefaults are fine for most of the tree; this just suppresses noise:
secret.ignored_paths— lockfiles,node_modules, binary doc assets, plustests/lint/fixtures/**andtests/ci/**(the latter embeds intentional hostile-workflow fixtures with${{ github.event.pull_request.head.sha }}strings that some entropy detectors misfire on)ignored_detectors: ['Generic High Entropy Secret']— kills the most common false positive, documentation/curl examplesCubic
No in-repo file. Custom rules are configured in their dashboard, optionally synced from
.cursor/rules/if the team uses those (we don't). Just need to install the app on the repo.Action items for the maintainer
Out of scope of a code change — these need account/dashboard work:
greptile.jsonbecomes dead config.gitguardian.yamlautomatically once the org is on the free OSS tier — if not yet installed, install via dashboardTest plan
node -e "JSON.parse(...)"parsesgreptile.jsonjs-yamlparses.gitguardian.yaml(v2 schema)npm run lint— cleannpm test— 187/187 pass (no behavior change)Summary by CodeRabbit
Summary by cubic
Add in-repo configs for Greptile (code review) and GitGuardian (secret scanning) on OSS free tiers. Tightens review focus on bugs/security and reduces noise without hiding real issues.
New Features
greptile.json:strictness: 2withcommentTypes: [logic, syntax]; precise skip rules viaignoreKeywords(e.g.,chore: release, dependabot) anddisabledLabels: ["release", "skip-review"]; section fields use objects; ignores lockfiles/assets. Adds project instructions, per-path rules, and pins.gemini/styleguide.mdandscripts/lib/gemini-tools.jsas references. Rule fixes: hooks-only “no console.log”; shell scripts requireset -e(aligned with the styleguide)..gitguardian.yaml: keeps detectors enabled; uses path-scoped ignores for known false positives (rules/**/security.md,**/SKILL.md) and suppresses noise from lockfiles,node_modules, binary docs, and test fixtures. Fails on real findings.Migration
.gitguardian.yaml.Written for commit e97b09c. Summary will update on new commits.