fix: show active hot update version
This commit is contained in:
@@ -1341,6 +1341,7 @@ ipcMain.handle("proxy-test", async () => proxy.testProxy());
|
|||||||
// 有效内容版本:优先已确认健康的热更版本,其次包内 hotContentVersion,兜底 app.getVersion()。
|
// 有效内容版本:优先已确认健康的热更版本,其次包内 hotContentVersion,兜底 app.getVersion()。
|
||||||
// 让设置页版本号随热更走(热更不替换 package.json,单纯 app.getVersion() 会永远停在打包版本)。
|
// 让设置页版本号随热更走(热更不替换 package.json,单纯 app.getVersion() 会永远停在打包版本)。
|
||||||
function effectiveAppVersion() {
|
function effectiveAppVersion() {
|
||||||
|
if (APP_ROOT !== BUNDLE_ROOT) return path.basename(APP_ROOT);
|
||||||
try {
|
try {
|
||||||
const v = hotstate.effectiveVersion(global.__HOT_BASE__);
|
const v = hotstate.effectiveVersion(global.__HOT_BASE__);
|
||||||
if (v) return v;
|
if (v) return v;
|
||||||
|
|||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "codex-market",
|
"name": "codex-market",
|
||||||
"version": "1.5.8",
|
"version": "1.5.9",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "codex-market",
|
"name": "codex-market",
|
||||||
"version": "1.5.8",
|
"version": "1.5.9",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"electron-updater": "^6.8.9",
|
"electron-updater": "^6.8.9",
|
||||||
|
|||||||
+2
-2
@@ -1,11 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "codex-market",
|
"name": "codex-market",
|
||||||
"version": "1.5.8",
|
"version": "1.5.9",
|
||||||
"description": "TD工具箱 / 技能商店 / 备份工具 —— 跨平台桌面客户端",
|
"description": "TD工具箱 / 技能商店 / 备份工具 —— 跨平台桌面客户端",
|
||||||
"author": "Codex Market",
|
"author": "Codex Market",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"main": "electron/bootstrap.js",
|
"main": "electron/bootstrap.js",
|
||||||
"hotContentVersion": "1.5.8",
|
"hotContentVersion": "1.5.9",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "electron .",
|
"start": "electron .",
|
||||||
"dist": "electron-builder",
|
"dist": "electron-builder",
|
||||||
|
|||||||
Reference in New Issue
Block a user