Skip to content

Add pre-commit config for repo hygiene and secret detection - #119

Open
Harshaada wants to merge 1 commit into
redhat-data-and-ai:mainfrom
Harshaada:hgaikwad-template-ui
Open

Add pre-commit config for repo hygiene and secret detection#119
Harshaada wants to merge 1 commit into
redhat-data-and-ai:mainfrom
Harshaada:hgaikwad-template-ui

Conversation

@Harshaada

@Harshaada Harshaada commented Aug 11, 2026

Copy link
Copy Markdown

No description provided.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • New Features
    • Added optional pre-commit checks to detect accidentally committed secrets.
  • Documentation
    • Updated Quick Start instructions with pre-commit setup guidance.
    • Added recommendations for enabling repository secret scanning and push protection.
    • Renumbered environment setup and server startup steps for clarity.

Walkthrough

The pull request adds pre-commit secret scanning with private-key detection and Gitleaks. The README documents installation, hook checks, GitHub Secret Scanning, and Push Protection.

Changes

Secret scanning setup

Layer / File(s) Summary
Pre-commit configuration and setup guidance
.pre-commit-config.yaml, README.md
Adds detect-private-key and Gitleaks v8.28.0 hooks. Documents optional pre-commit installation, secret-detection checks, and GitHub secret protections. Renumbers the setup steps.

Estimated code review effort: 1 (Trivial) | ~5 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive No pull request description was provided, so it does not explain the pre-commit and secret-detection changes. Add a brief description that summarizes the pre-commit configuration and README security guidance.
✅ Passed checks (4 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes the addition of pre-commit configuration for repository hygiene and secret detection.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Line 37: Update the environment configuration link in the README to reference
the heading’s exact rendered anchor, or add a stable explicit anchor and
reference it, so markdownlint-cli2 validates the fragment.
🪄 Autofix

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: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: a911cf3c-6f01-4822-95ed-dcb9fdd93f7e

📥 Commits

Reviewing files that changed from the base of the PR and between 582750b and c321003.

📒 Files selected for processing (2)
  • .pre-commit-config.yaml
  • README.md

Comment thread README.md
cp env.template .env
```

Edit `.env` and configure the required variables (see [Environment Configuration](#environment-configuration) below).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Fix the invalid environment link fragment.

Line 37 uses #environment-configuration, but markdownlint-cli2 reports this fragment as invalid for the target heading. Use the exact rendered anchor or add a stable explicit anchor.

The markdownlint-cli2 result identifies this fragment as invalid.

🧰 Tools
🪛 markdownlint-cli2 (0.23.2)

[warning] 37-37: Link fragments should be valid

(MD051, link-fragments)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` at line 37, Update the environment configuration link in the
README to reference the heading’s exact rendered anchor, or add a stable
explicit anchor and reference it, so markdownlint-cli2 validates the fragment.

Source: Linters/SAST tools

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant