Exclamation mark (!) after type/scope completely ignores commit
维护者通常 1 天内回复
已经有一个关联 PR 被合并了。
- #858 来自 @babblebey —— 已合并
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 55/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 冷清
- 技术栈
- javascript
- 领域
- release
调研方向
首先,使用 conventionalcommits 预设以及报告中展示的 feat!: 示例,在 @semantic-release/commit-analyzer 中复现该问题。将该解析路径与 BREAKING CHANGES 页脚的行为进行比较;当一个在 type 或 scope 后使用 ! 的提交能够触发预期的 major release,并且现有的分析输出已由测试覆盖时,即表示完成。
由索引模型根据 Issue 内容生成。
描述
I'm using the following config:
module.exports = {
branches: ['master', 'test_commit'],
repositoryUrl:
'ssh://git@*********',
plugins: [
[
'@semantic-release/commit-analyzer',
{
preset: 'conventionalcommits'
}
],
'@semantic-release/release-notes-generator',
'@semantic-release/changelog',
'@semantic-release/npm',
[
'@semantic-release/git',
{
message:
'chore(release): [XX-000] ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}'
}
]
]
};
This seems to work normally when committing feat: or fix: to trigger minor or patch versions, but when the commit message includes ! after scope it is completely ignored. This is the results of the analysis running on my machine with -d (dryrun)
[12:17:21 PM] [semantic-release] › ℹ Start step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ Analyzing commit: feat!: add new feature
semantic-release:commit-analyzer Analyzing with default rules +0ms
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ The commit should not trigger a release
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ Analyzing commit: feat: should trigger mnr
semantic-release:commit-analyzer Analyzing with default rules +1ms
semantic-release:commit-analyzer The rule { type: 'feat', release: 'minor' } match commit with release type 'minor' +0ms
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ The release type for the commit is minor
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ Analyzing commit: feat!: should trigger mjr
semantic-release:commit-analyzer Analyzing with default rules +0ms
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ The commit should not trigger a release
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ Analyzing commit: feat!: [XX-1234] Commit test
semantic-release:commit-analyzer Analyzing with default rules +1ms
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ The commit should not trigger a release
[12:17:21 PM] [semantic-release] [@semantic-release/commit-analyzer] › ℹ Analysis of 4 commits complete: minor release
[12:17:21 PM] [semantic-release] › ✔ Completed step "analyzeCommits" of plugin "@semantic-release/commit-analyzer"
[12:17:21 PM] [semantic-release] › ℹ The next release version is 4.1.0
As you can see above all the commits with feat!: give: The commit should not trigger a release
I'm running with --debug and I see that my config is loaded normally:
semantic-release:plugins options for @semantic-release/commit-analyzer/analyzeCommits: { preset: 'conventionalcommits' } +0ms
[12:17:12 PM] [semantic-release] › ✔ Loaded plugin "analyzeCommits" from "@semantic-release/commit-analyzer"
Adding BREAKING CHANGES: <desc> footer is respected normally.
- 主要语言
- JavaScript
- 星标
- 447
- 派生
- 82
- 平均合并
- 7 小时 53 分钟
- 30 天内合并 PR
- 9
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
semantic-release/commit-analyzer 的其他 Issue
-
released on @beta
难度 2/5 1-3 小时 新手友好度 65/100
semantic-release/commit-analyzer#921 · 8 条评论 · 7 个 reaction ·
维护者通常 1 天内回复
-
难度 3/5 1-2 天 新手友好度 42/100
semantic-release/commit-analyzer#805 · 6 条评论 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 25/100
semantic-release/commit-analyzer#802 · 1 条评论 ·
维护者通常 1 天内回复
-
Unexpected major release because commit description includes a line starting with "Breaking change"未关闭
难度 3/5 1-2 天 新手友好度 35/100
semantic-release/commit-analyzer#776 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 35/100
semantic-release/commit-analyzer#750 · 1 条评论 ·
维护者通常 1 天内回复
查看 semantic-release/commit-analyzer 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 62/100
woocommerce/woocommerce-google-analytics-integration#699 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 62/100
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
t0ggles
难度 2/5 1-3 小时 新手友好度 70/100
nolimits4web/swiper#8240 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 62/100
Inter-Actief/amelink#131 ·