Skip to content

Commit 31653c1

Browse files
committed
release 100.1.1
1 parent e1ab9d5 commit 31653c1

2 files changed

Lines changed: 9 additions & 7 deletions

File tree

scripts/convert-changelog.js

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -195,18 +195,20 @@ function main() {
195195

196196
fs.writeFileSync(outputPath, tsContent, 'utf-8');
197197

198+
// 读取 VERSION.txt 并同步到 version.ts
199+
const versionTxtPath = path.join(process.cwd(), 'VERSION.txt');
200+
const versionFromFile = fs.readFileSync(versionTxtPath, 'utf8').trim();
201+
console.log(`📄 VERSION.txt 版本: ${versionFromFile}`);
202+
updateVersionTs(versionFromFile);
203+
198204
// 检查是否在 GitHub Actions 环境中运行
199205
const isGitHubActions = process.env.GITHUB_ACTIONS === 'true';
200206

201207
if (isGitHubActions) {
202-
// 在 GitHub Actions 中,更新版本文件
203-
console.log('正在更新版本文件...');
208+
// 在 GitHub Actions 中,更新 VERSION.txt 为 CHANGELOG 最新版本
209+
console.log('正在更新 VERSION.txt...');
204210
updateVersionFile(latestVersion);
205211
updateVersionTs(latestVersion);
206-
} else {
207-
// 在本地运行时,只提示但不更新版本文件
208-
console.log('🔧 本地运行模式:跳过版本文件更新');
209-
console.log('💡 版本文件更新将在 git tag 触发的 release 工作流中完成');
210212
}
211213

212214
console.log(`✅ 成功生成 ${outputPath}`);

src/lib/version.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/* eslint-disable no-console */
22

3-
const CURRENT_VERSION = '100.1.0';
3+
const CURRENT_VERSION = '100.1.1';
44

55
// 导出当前版本号供其他地方使用
66
export { CURRENT_VERSION };

0 commit comments

Comments
 (0)