$npx -y skills add vibeeval/vibecosystem --skill commit-trailersCommit mesajlarina yapilandirilmis karar trailer'lari ekle. Constraint, Rejected, Confidence, Scope-risk, Not-tested trailer'lari ile karar baglamini koru.
| 1 | # Commit Trailers -- Structured Decision Context |
| 2 | |
| 3 | Supplement conventional commits with structured trailers that preserve the reasoning |
| 4 | behind a change. Future maintainers (and future agents) read commit history to |
| 5 | understand not just what changed, but why a specific approach was taken. |
| 6 | |
| 7 | ## Standard Trailers |
| 8 | |
| 9 | Add these after the commit body, separated by a blank line, when they add value: |
| 10 | |
| 11 | ``` |
| 12 | Constraint: <external limitation that shaped this approach> |
| 13 | Rejected: <alternative considered and the reason it was rejected> |
| 14 | Confidence: high | medium | low <how certain we are this is correct> |
| 15 | Scope-risk: low | medium | high <blast radius — how much can this break> |
| 16 | Not-tested: <what was not tested and why> |
| 17 | ``` |
| 18 | |
| 19 | --- |
| 20 | |
| 21 | ## When to Use Each Trailer |
| 22 | |
| 23 | | Trailer | When to Include | When to Skip | |
| 24 | |---------|----------------|--------------| |
| 25 | | `Constraint` | External limitation forced a non-obvious decision | No external constraints applied | |
| 26 | | `Rejected` | A reasonable alternative was considered and discarded | Only one approach was viable | |
| 27 | | `Confidence` | Correctness is uncertain or untested in key areas | Straightforward well-tested change | |
| 28 | | `Scope-risk` | Change touches shared infrastructure, middleware, auth, or core data paths | Isolated, single-purpose change | |
| 29 | | `Not-tested` | A gap in test coverage is intentional and known | All paths are tested | |
| 30 | |
| 31 | Not every commit needs trailers. A `fix: typo in error message` needs none. |
| 32 | A new auth middleware affecting every API call needs all five. |
| 33 | |
| 34 | --- |
| 35 | |
| 36 | ## Trailer Reference |
| 37 | |
| 38 | ### Constraint |
| 39 | An external limitation — browser API, hosting restriction, library limitation, |
| 40 | business rule, or environment constraint — that ruled out the obvious solution. |
| 41 | |
| 42 | ``` |
| 43 | Constraint: Safari 15 does not support the CSS :has() selector |
| 44 | Constraint: Redis unavailable in staging — in-memory fallback only |
| 45 | Constraint: Must stay on Node 18, no upgrade path in scope |
| 46 | Constraint: Third-party payment API does not support idempotency keys |
| 47 | ``` |
| 48 | |
| 49 | ### Rejected |
| 50 | An alternative that was seriously considered. Helps future maintainers understand |
| 51 | why the current approach exists instead of the simpler-looking one they are thinking of. |
| 52 | |
| 53 | ``` |
| 54 | Rejected: Redux — too much boilerplate for this feature's scope |
| 55 | Rejected: JWT stored in localStorage — XSS exposure, using httpOnly cookie instead |
| 56 | Rejected: Direct DB query — bypasses cache layer, use repository instead |
| 57 | Rejected: Polling every 5s — too much server load, went with SSE instead |
| 58 | ``` |
| 59 | |
| 60 | ### Confidence |
| 61 | Signal the quality of certainty around the correctness of the change. |
| 62 | `low` should trigger a code review comment or discussion before merge. |
| 63 | |
| 64 | ``` |
| 65 | Confidence: high |
| 66 | Confidence: medium — edge case with concurrent writes not covered by tests |
| 67 | Confidence: low — reversing this migration is complex, needs review before merge |
| 68 | ``` |
| 69 | |
| 70 | ### Scope-risk |
| 71 | Signal how much of the system this change can affect if it is wrong. |
| 72 | Helps reviewers and the team calibrate how carefully to review and test. |
| 73 | |
| 74 | ``` |
| 75 | Scope-risk: low |
| 76 | Scope-risk: medium — touches payment processing, needs manual smoke test |
| 77 | Scope-risk: high — auth middleware change, every authenticated endpoint affected |
| 78 | ``` |
| 79 | |
| 80 | ### Not-tested |
| 81 | Explicitly acknowledge a test gap. This is honest engineering, not an excuse. |
| 82 | A named gap is better than an invisible one. |
| 83 | |
| 84 | ``` |
| 85 | Not-tested: email delivery — no SMTP server in test environment |
| 86 | Not-tested: concurrent request behavior — requires load testing setup |
| 87 | Not-tested: Safari-specific rendering — no CI browser suite yet |
| 88 | Not-tested: DB rollback on payment failure — requires Stripe test mode setup |
| 89 | ``` |
| 90 | |
| 91 | --- |
| 92 | |
| 93 | ## Full Example |
| 94 | |
| 95 | ``` |
| 96 | feat: add rate limiting to API endpoints |
| 97 | |
| 98 | Implement token bucket algorithm for /api/* routes. |
| 99 | Limits: 100 requests/min for free tier, 1000 for paid tier. |
| 100 | Exceeding the limit returns 429 with Retry-After header. |
| 101 | |
| 102 | Constraint: Redis required for distributed rate limiting — in-memory does not work across multiple instances |
| 103 | Rejected: express-rate-limit — lacks per-user tier support without significant custom logic |
| 104 | Confidence: high |
| 105 | Scope-risk: medium — affects all /api/* routes, auth and webhook routes excluded |
| 106 | Not-tested: sustained 10K+ req/min behavior — requires dedicated load test environment |
| 107 | ``` |
| 108 | |
| 109 | --- |
| 110 | |
| 111 | ## Format Rules |
| 112 | |
| 113 | - Trailers go AFTER the commit body, separated by a blank line |
| 114 | - One trailer per line, no line wrapping |
| 115 | - `Rejected` may appear multiple times (one per rejected alternative) |
| 116 | - Only include trailers that add genuine value — avoid mechanical inclusion |
| 117 | - `Confidence: low` is a signal for the team, not a reason to skip the commit |
| 118 | - This format supplements, not replaces, the conventional commit type prefix |
| 119 | |
| 120 | ## Integration with Other Rules |
| 121 | |
| 122 | - `safety-and-quality.md` defines the base commit format (`<type>: <description>`) |
| 123 | - This rule adds optional trailers on top of that format |
| 124 | - `full- |