chore: add Claude Code setup adapted to this repo#27
Merged
Conversation
Adds CLAUDE.md, project-level .claude/ config, two agents (pr-readiness, reload-fixtures) and an update-api-spec skill, all targeted at this repo's Taskfile / Elasticsearch / API Platform setup. settings.local.json is gitignored. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
✅ No changes detected in API specification |
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a project-level Claude Code setup (
CLAUDE.md+.claude/) tailored to this repo's Taskfile / Elasticsearch / API Platform conventions. Starts from a config copied from a Doctrine/Yarn-flavoured project and adapts it to fit here.No production code is touched.
Files Changed
CLAUDE.md(new) — onboarding doc for Claude Code: project purpose (read-only ES-backed API, data owned byevent-database-imports), Taskfile-based commands, request-flow architecture (Dto → State Provider → ElasticSearchIndex), and the non-obvious conventions (no Doctrine entities, PHPUnit fails on deprecations, etc.)..claude/settings.json(new) — permission allow/deny/ask lists,SessionStarthook to bring updocker compose,PreToolUseblock on lock files /.env.local,PostToolUseauto-format hooks for PHP / Twig / composer.json / YAML / Markdown using this repo's services (prettier,markdownlint— not anodeservice, which doesn't exist here), and aStophook runningbin/console lint:container. Merged the previoussettings.local.jsonMCP keys in here..claude/settings.local.json(new, empty{}) — gitignored per-user override slot..gitignore— ignore.claude/settings.local.json(same pattern as.env.local)..claude/agents/pr-readiness.md(new) — mirrors.github/workflows/*.yaml: composer validate/normalize, PHP/Twig/YAML/Markdown coding-standards, PHPStan, fixtures +task api:test,task api:spec:exportdiff check, CHANGELOG check..claude/agents/reload-fixtures.md(new) — replaces an inheritedcreate-migrationagent that assumed Doctrine. Handles the README's "No alive nodes" Elasticsearch recovery dance..claude/skills/update-api-spec/SKILL.md(new) — points attask api:spec:exportand the singlepublic/spec.yaml(not the inherited two-fileapi-spec-v1.{yaml,json}).Test Plan
SessionStarthook brings up the docker compose stack..phpfile —PostToolUserunsphp-cs-fixerthenphpstanon the file..yamlfile —PostToolUserunsprettiervia theprettiercompose service..mdfile —PostToolUserunsmarkdownlint --fixvia themarkdownlintcompose service..env.localorcomposer.lock—PreToolUsehook blocks the write.pr-readinessagent — all CI-equivalent checks execute successfully.update-api-specskill after a no-op resource change — produces a cleangit diff public/spec.yaml.🤖 Generated with Claude Code