下面展现一下小编的 commit messagenode
这是生成的 CHANGELOGgit
目前规范使用较多的是 Angular 团队的规范, 继而衍生了 Conventional Commits specification. 不少工具也是基于此规范, 它的 message 格式以下:github
<type>(<scope>): <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
复制代码
每一个提交消息由header,body和footer组成,其中 body 和 footer 能够省略express
header只有一行,包括三个字段:type
(必需)、scope
(可选)和subject
(必需)json
范围能够是指定提交更改位置的任何内容,能够*
在更改影响多个范围时使用bash
这次commit的简洁描述,不超过50个字符, 推荐使用英语提交commit。app
.
body 部分是对本次 commit 的详细描述,能够分红多行, 好比描述与提交以前有什么不一样。ide
全部重大更改都必须做为页脚中的更改块说起,它应以“BREAKING CHANGE”一词开头:空一到两行。而后,提交消息的其他部分是对更改,理由和迁移说明的描述。工具
BREAKING CHANGE: isolate scope bindings definition has changed and
the inject option for the directive controller injection was removed.
To migrate the code follow the example below:
Before:
scope: {
myAttr: 'attribute',
myBind: 'bind',
myExpression: 'expression',
myEval: 'evaluate',
myAccessor: 'accessor'
}
After:
scope: {
myAttr: '@',
myBind: '@',
myExpression: '&',
// myEval - usually not useful, but in cases where the expression is assignable, you can use '='
myAccessor: '=' // in directive's template change myAccessor() to myAccessor } The removed `inject` wasn't generaly useful for directives so there should be no code using it.
复制代码
关闭 issus 应该在页脚的单独行中列出,前缀为“Closes”关键字,以下所示:性能
Closes #234
// 多个
Closes #123, #245, #992
复制代码
这是我本身项目提交时使用的message, 你们能够参考,下面是手动敲的,可使用工具 commitizen/cz-cli, 自动生成标准的commit message, 在此很少介绍
feat: write log message into file
Put log message into appoint dir, it will create the dir if not exist
复制代码
refactor(package.json): update nodejs version and license
The version was 1.0.0, the license was ISC before update, and now, the version is 0.0.1, license is MIT
复制代码