{"id":49618625,"url":"https://github.com/rasterandstate/commit-coach","last_synced_at":"2026-05-05T00:09:12.218Z","repository":{"id":318572142,"uuid":"1071652743","full_name":"rasterandstate/commit-coach","owner":"rasterandstate","description":"An intelligent commit analysis tool that provides insights and coaching for code changes.","archived":false,"fork":false,"pushed_at":"2025-11-14T22:41:30.000Z","size":1028,"stargazers_count":1,"open_issues_count":12,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-14T23:37:18.992Z","etag":null,"topics":["automation","ci-cd","code-quality","code-review","commit-analysis","git","github-action","insights","nodejs","security","testing","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rasterandstate.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-07T16:22:36.000Z","updated_at":"2025-11-14T22:41:34.000Z","dependencies_parsed_at":null,"dependency_job_id":"dbe48045-4d3e-4386-a74a-da9a67078e72","html_url":"https://github.com/rasterandstate/commit-coach","commit_stats":null,"previous_names":["rasterandstate/commit-coach"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/rasterandstate/commit-coach","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rasterandstate%2Fcommit-coach","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rasterandstate%2Fcommit-coach/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rasterandstate%2Fcommit-coach/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rasterandstate%2Fcommit-coach/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rasterandstate","download_url":"https://codeload.github.com/rasterandstate/commit-coach/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rasterandstate%2Fcommit-coach/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32629779,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-04T10:08:07.713Z","status":"ssl_error","status_checked_at":"2026-05-04T10:08:02.005Z","response_time":58,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","ci-cd","code-quality","code-review","commit-analysis","git","github-action","insights","nodejs","security","testing","typescript"],"created_at":"2026-05-05T00:09:05.672Z","updated_at":"2026-05-05T00:09:12.210Z","avatar_url":"https://github.com/rasterandstate.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\".github/assets/commit-coach.png\" alt=\"Commit Coach Owl Mascot\" width=\"200\" /\u003e\n\u003c/div\u003e\n\n# Commit Coach\n\n[![GitHub Marketplace](https://img.shields.io/badge/Marketplace-Commit%20Coach-blue.svg?logo=github\u0026logoColor=white)](https://github.com/marketplace/actions/commit-coach)\n[![Version](https://img.shields.io/github/v/release/rasterandstate/commit-coach?logo=github)](https://github.com/rasterandstate/commit-coach/releases)\n[![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)\n[![Node.js](https://img.shields.io/badge/node-%3E%3D24.0.0-brightgreen.svg)](https://nodejs.org/)\n\nAn intelligent commit analysis tool that provides insights and coaching for code changes.\n\n## What it does\n\nAnalyzes commits and provides intelligent insights like:\n- **\"You added ~120 lines but didn't write tests for module X\"**\n- **\"You removed public method foo() - are downstream consumers affected?\"**\n- **\"You added feature flags - consider documenting them\"**\n- **\"This is a large commit (300+ lines) - consider breaking it up\"**\n\n## 🎬 Live Demo\n\nSee Commit Coach in action with real git workflows:\n\n[![asciicast](https://asciinema.org/a/RVu88qm4Ya1OmLVgKyeiH5taB.svg)](https://asciinema.org/a/RVu88qm4Ya1OmLVgKyeiH5taB)\n\n## Quick Start\n\n### GitHub Actions (Recommended)\n\n#### Marketplace Installation (Coming Soon)\nOnce published to the GitHub Marketplace, you'll be able to install with one click or use:\n\n```yaml\nname: Commit Coach\non: [push, pull_request]\njobs:\n  commit-coach:\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@v4\n      with:\n        fetch-depth: 0\n    - uses: rasterandstate/commit-coach@v1\n      with:\n        github-token: ${{ secrets.GITHUB_TOKEN }}\n```\n\n#### Direct Repository Installation\nFor now, you can use the action directly from the repository:\n\n```yaml\nname: Commit Coach\non: [push, pull_request]\njobs:\n  commit-coach:\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@v4\n      with:\n        fetch-depth: 0\n    - uses: rasterandstate/commit-coach@v1\n      with:\n        github-token: ${{ secrets.GITHUB_TOKEN }}\n```\n\n### CLI Installation\n\n```bash\n# Install from source (after cloning the repository)\nnpm install\nnpm run build\n\n# Initialize config\n./dist/index.js init\n\n# Analyze current commit\n./dist/index.js analyze\n\n# GitHub integration\n./dist/index.js github --pr 123\n```\n\n## Configuration\n\nCreate `.commit-coach.yml`:\n\n```yaml\nrules:\n  - id: missing-tests\n    enabled: true\n    severity: warning\n    conditions: [\"sourceFilesWithoutTests.length \u003e 0\"]\n    message: \"Consider adding tests for new/modified source files\"\n\noutput:\n  format: console  # console, comment, status-check, report\n  maxInsights: 10\n\nintegrations:\n  github:\n    token: \"${GITHUB_TOKEN}\"\n    commentOnPR: true\n    createStatusCheck: true\n```\n\n## Git Hooks\n\nThis project uses [Lefthook](https://github.com/evilmartians/lefthook) for git hooks to ensure code quality:\n\n### Pre-commit Hooks\n- **Formatting**: Runs Prettier to check code formatting\n- **Linting**: Runs ESLint to check code quality\n- **Type Checking**: Runs TypeScript compiler to check types\n- **Tests**: Runs tests for changed files\n\n### Pre-push Hooks\n- **Build**: Ensures the project compiles successfully\n- **Test Coverage**: Runs full test suite with coverage\n- **Action Build**: Builds the GitHub Action\n\n### Setup\n```bash\n# Install hooks (done automatically after npm install)\nnpm run hooks:install\n\n# Run hooks manually\nnpm run hooks:run pre-commit\nnpm run hooks:run pre-push\n\n# Uninstall hooks\nnpm run hooks:uninstall\n```\n\n## Built-in Rules\n\n### 🔒 Security Rules\n- **Hardcoded Secrets**: Detects API keys, tokens, and credentials\n- **Security Patterns**: Identifies potential security vulnerabilities\n\n### 🧪 Code Quality Rules\n- **Test Coverage**: Warns when source files lack tests\n- **Code Quality**: Analyzes code patterns and quality metrics\n\n### 📝 Workflow Rules\n- **Large Commits**: Warns about large commits (200+ lines)\n- **Commit Messages**: Flags short or unclear commit messages\n- **TODO Comments**: Detects TODO/FIXME comments in code\n\n### 🔄 API \u0026 Documentation Rules\n- **Public API Changes**: Detects API removals and new APIs\n- **Documentation**: Suggests updating docs for new features\n- **Feature Flags**: Identifies new feature flags that need documentation\n- **Breaking Changes**: Detects potential breaking changes\n\n📖 **[Complete Rules Documentation](docs/RULES.md)** - Learn how to create custom rules and configure all available options.\n\n📋 **[Configuration Examples](docs/EXAMPLES.md)** - See practical examples for different project types and team workflows.\n\n## Documentation\n\n- 📚 **[Documentation Index](docs/README.md)** - Complete documentation overview\n- 📖 **[Rules Reference](docs/RULES.md)** - All available variables, conditions, and examples\n- 📋 **[Configuration Examples](docs/EXAMPLES.md)** - Project-specific configurations\n- 🚀 **[Usage Examples](examples/USAGE.md)** - Command-line usage and CI/CD integration\n\n## Action Inputs\n\n| Input | Description | Required | Default |\n|-------|-------------|----------|---------|\n| `github-token` | GitHub token for API access | ✅ | - |\n| `config-path` | Path to commit-coach config file | ❌ | `.commit-coach.yml` |\n| `commit-hash` | Specific commit to analyze | ❌ | Current commit |\n| `pr-number` | Pull request number | ❌ | Auto-detected |\n| `comment` | Post comment on PR | ❌ | `true` |\n| `status-check` | Create status check | ❌ | `true` |\n\n## License\n\nMIT License - see LICENSE file for details.\n.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frasterandstate%2Fcommit-coach","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frasterandstate%2Fcommit-coach","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frasterandstate%2Fcommit-coach/lists"}