- 启动链路 P1-P7 修复:预算对齐、完成事件推送、端口占用提示、前端阶段文案接管 - 静态缓存按 IS_FROZEN 区分开发/打包态,bootPhaseOwned 竞态修复 - 一键执行与参数配置统一收口到插件界面,定时任务引用 config_id - 环境包迁移到 %LOCALAPPDATA%\37duAutomation\python-env,重装零解压 - shell-updater:缓存包 sha256 校验、静默升级后自动拉起新版、自动清理旧安装包 - after-pack 钩子生成 shell.version 修复打包态版本识别 - 插件 xq0031/xq0045 迁移至 plugins/XQ0001-0100/ 号段分桶中文目录
15 lines
690 B
JavaScript
15 lines
690 B
JavaScript
// electron-builder afterPack 钩子:把 package.json 版本号写入 exe 同级 shell.version。
|
|
// shell-updater 靠这个文件判定"打包态 + 本机版本",缺失会被误判为源码开发模式、
|
|
// 不参与壳子自更新(win-unpacked 根目录 = 安装后 exe 同级目录)。
|
|
"use strict";
|
|
|
|
const fs = require("fs");
|
|
const path = require("path");
|
|
|
|
exports.default = async function afterPack(context) {
|
|
const pkg = require(path.join(__dirname, "..", "package.json"));
|
|
const target = path.join(context.appOutDir, "shell.version");
|
|
fs.writeFileSync(target, `${pkg.version}\n`, "utf-8");
|
|
console.log(`[after-pack] shell.version -> ${target} (${pkg.version})`);
|
|
};
|