Skip to content

docs(contributing): add Conventional Commits and Branches section#208

Open
yassin-berriai wants to merge 1 commit into
mainfrom
docs/conventional-commits-and-branches
Open

docs(contributing): add Conventional Commits and Branches section#208
yassin-berriai wants to merge 1 commit into
mainfrom
docs/conventional-commits-and-branches

Conversation

@yassin-berriai
Copy link
Copy Markdown
Contributor

What

Adds a new Commit and Branch Conventions section to docs/extras/contributing_code.md covering:

  • Conventional Commits 1.0.0 format, allowed types, the lowercase-leading-description rule, and breaking-change syntax (!).
  • Conventional Branches format, allowed types (feature | bugfix | hotfix | release | chore), and the protected-branch bypass list (main, litellm_internal_staging, dependabot/*, gh-readonly-queue/*).
  • How to install the opt-in hooks via make install-hooks and the --no-verify escape hatch.

The checklist at the top of the page also gains a "Follow the Commit and Branch Conventions" item.

Why

Companion to BerriAI/litellm#28703, which introduces:

  • .githooks/commit-msg and .githooks/pre-push (opt-in)
  • A required CI workflow that validates PR titles
  • A make install-hooks target

Per the team convention, the detailed documentation lives in this repo rather than in CONTRIBUTING.md of the main repo. CONTRIBUTING.md in the main repo links here.

Preview

The new section sits between "Contributor License Agreement (CLA)" and "Proxy (Backend)", with this outline:

  • Commit message format (with examples)
  • Branch naming (with examples and bypass list)
  • Installing the hooks

Documents the two community specs that BerriAI/litellm#28703 introduces
git hooks and a CI check for:

- Conventional Commits 1.0.0 — commit / PR-title format, allowed types,
  the lowercase-leading-description rule, and breaking-change syntax.
- Conventional Branches — branch format, allowed types, and the
  protected-branch bypass list (main, litellm_internal_staging,
  dependabot/*, gh-readonly-queue/*).
- How to install the opt-in hooks via 'make install-hooks' and the
  --no-verify escape hatch.

CONTRIBUTING.md in the main repo now points here instead of duplicating
the content.

Companion to BerriAI/litellm#28703.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 23, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
litellm Ready Ready Preview, Comment May 23, 2026 5:38pm

Request Review

yassin-berriai pushed a commit to BerriAI/litellm that referenced this pull request May 23, 2026
Resolves two findings from the automated code review:

1. CONTRIBUTING.md: shrink the new Conventional Commits / Branches
   section to a 2-line pointer at docs.litellm.ai. Per the team
   convention, the full documentation lives in the litellm-docs
   repo — see BerriAI/litellm-docs#208 for the companion change that
   adds the section to docs/extras/contributing_code.md.

2. .githooks/commit-msg: tighten the subject regex to also reject an
   uppercase first letter in the description. CI's subjectPattern is
   ^(?![A-Z]).+$ so the previous local hook would accept 'feat: Add
   thing' which would then fail the PR-title check. The local hook is
   now the strictly tighter of the two gates. Test cases extended to
   cover both the new rejection and the digit/symbol-start cases that
   remain allowed.

Resolves LIT-3306

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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