Skip to content

chore: align with ks-backend conventions (clean code, precommit, changelog)#2

Merged
arnav2 merged 1 commit intomainfrom
chore/align-with-ks-backend-conventions
Apr 17, 2026
Merged

chore: align with ks-backend conventions (clean code, precommit, changelog)#2
arnav2 merged 1 commit intomainfrom
chore/align-with-ks-backend-conventions

Conversation

@arnav2
Copy link
Copy Markdown
Contributor

@arnav2 arnav2 commented Apr 17, 2026

Summary

Brings ks-cookbook in line with the stability and cleanliness conventions we already run in ks-backend.

Added

  • .pre-commit-config.yaml — runs make fix then make lint on every commit.
  • .cursor/rules/ — three rule files mirroring the ks-backend style:
    • python_clean_code.mdc — SRP, size limits, forbidden smells, the four prompt invariants.
    • flagship_author.mdc — file layout, README template, agent wiring, schema shape, Makefile entry, PR checklist.
    • recipe_author.mdc — ≤100-LOC cap, frontmatter, shared session helper, smoke-test bar.
  • CHANGELOG.md — covers v0.1.0, v0.1.1, and [Unreleased].

Changed

  • Makefile — added fix, format, and install-dev targets; tightened .PHONY.
  • pyproject.toml — added pre-commit>=3.7 to [dependency-groups].dev.
  • CLAUDE.md — new "Style rules (load these first)" section pointing future agents at the cursor rules, plus refreshed command table.

Not changed

  • No flagship code, no agent prompts, no output format.
  • No new dependencies beyond pre-commit.

Test plan

  • make lint passes on the branch
  • make test passes (13/13)
  • uv sync --all-packages clean
  • CI on this PR: test (3.11) + test (3.12) green

Once CI is green this is ready to merge.

🤖 Generated with Claude Code

…commit, changelog)

Brings cookbook in line with ks-backend's style and stability setup.

- Add .pre-commit-config.yaml with ruff-fix + ruff-check hooks
- Add .cursor/rules/ — python_clean_code, flagship_author, recipe_author
  (mirrors ks-backend's Uncle Bob-style rule set, adapted for the cookbook's
  prompt invariants, schema requirements, and recipe LOC cap)
- Add CHANGELOG.md covering v0.1.0, v0.1.1, and [Unreleased]
- Makefile: add fix / format / install-dev targets; tighten .PHONY list
- pyproject.toml: add pre-commit to [dependency-groups].dev
- CLAUDE.md: point future agents at the cursor rules before they edit anything,
  and refresh the commands table to match the new targets

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@arnav2 arnav2 requested a review from frankgu968 April 17, 2026 20:24
@arnav2 arnav2 merged commit 8f7c4d5 into main Apr 17, 2026
2 checks passed
@arnav2 arnav2 requested a review from a team April 17, 2026 20:25
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