fix(installer/updater): 修复版本显示和更新流程问题

- 在installer.lua中添加INSTALLER_VERSION常量替代_VERSION
- 更新update.lua中的版本检查流程和用户提示
- 改进updater的界面显示,添加顶部名称栏
- 统一更新确认提示为小写[y/n]
- 将"stage"改为更准确的"step"描述
This commit is contained in:
2025-09-01 09:42:28 +08:00
parent 6f0a33f75d
commit 44a44caffe
2 changed files with 29 additions and 6 deletions

View File

@@ -1,6 +1,7 @@
-- LeonOS installer
local INSTALLER_VERSION = "0.1.1"
local DEFAULT_ROM_DIR = "/rc"
print("Start loading LeonOS installer...")
print("[Installer] Loading module 1")
local function dl(f)
@@ -86,7 +87,7 @@ for y=2, term.getSize() do
end
term.at(1, 2)
tu.coloredPrint(colors.yellow,
"LeonOS Installer (v".._VERSION..")\n=======================")
"LeonOS Installer (v"..INSTALLER_VERSION..")\n=======================")
tu.coloredPrint("You are going to install LeonOS to your computer.")
tu.coloredPrint("This will ",colors.red,"overwrite any existing files", colors.white, " in the installation directory.")
tu.coloredPrint(colors.yellow, "Are you sure? (y/n)")