From 20613844dbf6a2914c951ad678b2726d2dc63739 Mon Sep 17 00:00:00 2001 From: zhbaor Date: Thu, 10 Oct 2024 09:46:24 +0800 Subject: [PATCH] =?UTF-8?q?webview=E8=AF=BB=E5=8F=96ui/dist/index.html?= =?UTF-8?q?=E3=80=81=E6=98=BE=E7=A4=BA=E7=89=88=E6=9C=AC=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- main.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 325867c..a330caa 100644 --- a/README.md +++ b/README.md @@ -9,5 +9,5 @@ 前端运行 `npm run build` 生成 `ui/dist`,之后安装 PyInstaller,运行 ```bash -pyinstaller -w -F --add-data ui/dist:dist main.py +pyinstaller -w -F --add-data ui/dist:ui/dist main.py ``` diff --git a/main.py b/main.py index 05b3d74..3374ddc 100644 --- a/main.py +++ b/main.py @@ -4,6 +4,8 @@ from subprocess import PIPE, STDOUT, Popen import webview +version = "2024-10-10" + config_path = Path("launcher.json") try: @@ -65,7 +67,7 @@ class Api: custom_event(line) -window = webview.create_window("mower-ng launcher", "dist/index.html", js_api=Api()) +window = webview.create_window(f"mower-ng launcher {version}", "ui/dist/index.html", js_api=Api()) webview.start() with config_path.open("w") as f: