Skip to content

Commit 2d2bb91

Browse files
committed
chore: alpha publish prerelease
1 parent 44a2feb commit 2d2bb91

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"changes": [
3+
{
4+
"packageName": "@coze-arch/rush-publish-plugin",
5+
"comment": "alpha publish prerelease",
6+
"type": "patch"
7+
}
8+
],
9+
"packageName": "@coze-arch/rush-publish-plugin",
10+
"email": "289056872@qq.com"
11+
}

packages/rush-plugins/publish/src/action/publish/version.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ const calculateNewVersion = (
5252
return `${baseVersion}-beta.1`;
5353
}
5454
case BumpType.ALPHA: {
55-
// 否则基于当前版本创建新的 alpha 版本
56-
const baseVersion = `${major}.${minor}.${patch}`;
57-
// 生成随机哈希值
55+
// Based on the next patch version to create alpha version
56+
const nextPatch = prerelease.length > 0 ? patch : patch + 1;
57+
const baseVersion = `${major}.${minor}.${nextPatch}`;
5858
return `${baseVersion}-alpha.${sessionId || randomHash(6)}`;
5959
}
6060
default: {

0 commit comments

Comments
 (0)