@checkmarkdevtools/commitlint-plugin-rai
v0.1.6
Published
Commitlint plugin for RAI footer validation
Downloads
376
Maintainers
Readme
@checkmarkdevtools/commitlint-plugin-rai
Installation 🔧
npm install --save-dev @checkmarkdevtools/commitlint-plugin-raiUsage 🚦
Add the plugin to your commitlint.config.js:
export default {
extends: ['@commitlint/config-conventional'],
plugins: ['@checkmarkdevtools/commitlint-plugin-rai'],
rules: {
'rai-footer-exists': [2, 'always'],
},
};Once this is in place, commitlint will refuse to proceed until a valid RAI trailer is present.
Valid Trailers 📌
Pick exactly one. Skip it and the commit fails. Use more than one and the commit also fails.
No negotiations.
Authored-by: [Human] <email>— all you, no AI involvedCommit-generated-by: [AI Tool] <email>— AI wrote the commit message, you wrote the codeAssisted-by: [AI Tool] <email>— AI helped some, you were still drivingCo-authored-by: [AI Tool] <email>— roughly 50/50, like actual pair programmingGenerated-by: [AI Tool] <email>— AI did most of it, you supervised
All patterns are case-insensitive, because enforcing honesty does not require enforcing capitalization.
Why This Exists ⚖️
If two humans pair program, both names go on the commit. If an AI helps and we pretend it didn’t happen, that’s a choice, but it’s a strange one.
Git already supports trailers. This plugin just closes the gap between “we could do this” and “we actually do this,” by making attribution a default instead of a discussion.
If you want the longer version of that reasoning, it’s written up at Did AI Erase Attribution?.
This plugin is the boring enforcement layer that follows.
Requirements ⚙️
- Node.js >= 20.0.0
- @commitlint/cli >= 19.0.0
License 📄
PolyForm Shield License 1.0.0
