longwind1984_galaxy-view/version-bump.mjs
Rick 599e85d243 M0 脚手架 + 性能尖刺:stock 3d-force-graph + 真实数据基准(S1-S4)
- obsidian-sample-plugin 模板(esbuild 0.25/TS 5.8/eslint-plugin-obsidianmd/vitest)
- three@0.184 + 3d-force-graph@1.80 + d3-force-3d@3.0.6,prod 包 1.3MB
- SpikeView:黑底 + bloom(UnrealBloom+OutputPass)+ FPS/drawcall HUD
- 基准:S1 沉降后 20s 环绕 / S2 冷布局 longtask / S3 含未解析 / S4 泄漏金丝雀
- 确定性种子布局(FNV-1a),结果写 _galaxy_bench/*.json
- 设计文档三份 + 实施计划入 docs/design/

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-06-12 17:30:39 +08:00

17 lines
758 B
JavaScript

import { readFileSync, writeFileSync } from 'fs';
const targetVersion = process.env.npm_package_version;
// read minAppVersion from manifest.json and bump version to target version
const manifest = JSON.parse(readFileSync('manifest.json', 'utf8'));
const { minAppVersion } = manifest;
manifest.version = targetVersion;
writeFileSync('manifest.json', JSON.stringify(manifest, null, '\t'));
// update versions.json with target version and minAppVersion from manifest.json
// but only if the target version is not already in versions.json
const versions = JSON.parse(readFileSync('versions.json', 'utf8'));
if (!(targetVersion in versions)) {
versions[targetVersion] = minAppVersion;
writeFileSync('versions.json', JSON.stringify(versions, null, '\t'));
}