Commit 规范
目标
规范开发者每次提交代码到远程仓库
提交信息结构
统一格式:
<type>(scope?): <short summary>
[optional body]
[optional footer(s)]
type:本次提交的类型(必填)scope:影响范围(可选,比如模块名、包名)short summary:一句话说明做了什么(必填)body:必要时补充动机、实现思路(可选,多行)footer:放关联 issue、BREAKING CHANGE 等(可选)
示例:
feat(api): add user login endpoint
Support JWT-based login and return user profile in response.
Closes #123
类型(type)约定