diff --git a/ai/backend_prompt_template.md b/ai/backend_prompt_template.md index 1aa846d..5b9cf44 100644 --- a/ai/backend_prompt_template.md +++ b/ai/backend_prompt_template.md @@ -32,18 +32,24 @@ Code patterns to follow: - Variable names: use explicit, descriptive names — never single-letter or abbreviated variables (e.g., use $sponsorship not $s, $event not $e) Git commit style: -- Present tense, imperative mood (add, create, test, fix) -- Lowercase -- Short (3-6 words) -- Match patterns found in git history +- Subject: present tense, imperative mood (add, create, test, fix) +- Subject: lowercase, short (3-6 words) +- Match subject patterns found in git history +- Add a body when the change needs explanation beyond the subject — + e.g., why the change was made, non-obvious tradeoffs, or notable + implementation details. Skip the body for trivial/self-evident commits. +- Separate subject and body with a blank line; wrap body at ~72 columns Git commits: - Tests should be committed first, before implementation -- One commit per file - each new file gets its own commit -- Make commits SMALL and FREQUENT - every meaningful change should be a commit +- Group related changes together in a single commit (e.g., a new class + plus its registration, or a getter plus the property it exposes). + Avoid mixing unrelated concerns in one commit. +- Keep commits small and focused — prefer many small commits over few + large ones, but don't artificially split a single logical change + across multiple commits - Commits are for reviewing and documenting the development of code -- A commit can be as simple as adding one import, one getter, one property, etc. -- Don't wait to commit - commit as you go +- Don't wait to commit — commit as you go - Run `php-cs-fixer fix` on worked on directories before committing Branch naming: diff --git a/ai/frontend_prompt_template.md b/ai/frontend_prompt_template.md index 24eb7c3..80852e2 100644 --- a/ai/frontend_prompt_template.md +++ b/ai/frontend_prompt_template.md @@ -22,18 +22,24 @@ Code patterns to follow: - Variable names: use explicit, descriptive names — never single-letter or abbreviated variables (e.g., use sponsorship not s, event not e) Git commit style: -- Present tense, imperative mood (add, create, test, fix) -- Lowercase -- Short (3-6 words) -- Match patterns found in git history +- Subject: present tense, imperative mood (add, create, test, fix) +- Subject: lowercase, short (3-6 words) +- Match subject patterns found in git history +- Add a body when the change needs explanation beyond the subject — + e.g., why the change was made, non-obvious tradeoffs, or notable + implementation details. Skip the body for trivial/self-evident commits. +- Separate subject and body with a blank line; wrap body at ~72 columns Git commits: - Tests should be committed first, before implementation -- One commit per file - each new file gets its own commit -- Make commits SMALL and FREQUENT - every meaningful change should be a commit +- Group related changes together in a single commit (e.g., a new class + plus its registration, or a getter plus the property it exposes). + Avoid mixing unrelated concerns in one commit. +- Keep commits small and focused — prefer many small commits over few + large ones, but don't artificially split a single logical change + across multiple commits - Commits are for reviewing and documenting the development of code -- A commit can be as simple as adding one import, one getter, one property, etc. -- Don't wait to commit - commit as you go +- Don't wait to commit — commit as you go Branch naming: - Use kebab-case (e.g., node-page text-page)