CHANGELOG.md 配置
默認(rèn)情況下,standard-version 只會(huì)在 CHANGELOG.md 中記錄 feat 和 fix 類型的提交。如果想記錄其他類型的提交,需要如下步驟:
在項(xiàng)目的根目錄下創(chuàng)建一個(gè)名為 .versionrc 的文件,并粘貼復(fù)制一下內(nèi)容:
{
"types": [
{"type": "chore", "section":"Others", "hidden": false},
{"type": "revert", "section":"Reverts", "hidden": false},
{"type": "feat", "section": "Features", "hidden": false},
{"type": "fix", "section": "Bug Fixes", "hidden": false},
{"type": "improvement", "section": "Feature Improvements", "hidden": false},
{"type": "docs", "section":"Docs", "hidden": false},
{"type": "style", "section":"Styling", "hidden": false},
{"type": "refactor", "section":"Code Refactoring", "hidden": false},
{"type": "perf", "section":"Performance Improvements", "hidden": false},
{"type": "test", "section":"Tests", "hidden": false},
{"type": "build", "section":"Build System", "hidden": false},
{"type": "ci", "section":"CI", "hidden":false}
]
}
"type" commit 類型
"section" 不同的 commit 類型所在 CHANGELOG.md 中的區(qū)域
"hidden" 是否在 CHANGELOG.md 中顯示