mirror of
https://github.com/LmeSzinc/AzurLaneAutoScript.git
synced 2025-01-09 06:07:40 +08:00
Add: Show detailed commit history in updater
This commit is contained in:
parent
25a4162d27
commit
f3a683de76
@ -82,9 +82,6 @@ Deploy:
|
||||
OcrClientAddress: 127.0.0.1:22268
|
||||
|
||||
Update:
|
||||
# Use auto update and builtin updater feature
|
||||
# This may cause problem https://github.com/LmeSzinc/AzurLaneAutoScript/issues/876
|
||||
EnableReload: true
|
||||
# Check update every X minute
|
||||
# [Disable] -1
|
||||
# [Default] 5
|
||||
|
@ -82,9 +82,6 @@ Deploy:
|
||||
OcrClientAddress: 127.0.0.1:22268
|
||||
|
||||
Update:
|
||||
# Use auto update and builtin updater feature
|
||||
# This may cause problem https://github.com/LmeSzinc/AzurLaneAutoScript/issues/876
|
||||
EnableReload: true
|
||||
# Check update every X minute
|
||||
# [Disable] -1
|
||||
# [Default] 5
|
||||
|
@ -82,9 +82,6 @@ Deploy:
|
||||
OcrClientAddress: 127.0.0.1:22268
|
||||
|
||||
Update:
|
||||
# Use auto update and builtin updater feature
|
||||
# This may cause problem https://github.com/LmeSzinc/AzurLaneAutoScript/issues/876
|
||||
EnableReload: true
|
||||
# Check update every X minute
|
||||
# [Disable] -1
|
||||
# [Default] 5
|
||||
|
@ -82,9 +82,6 @@ Deploy:
|
||||
OcrClientAddress: 127.0.0.1:22268
|
||||
|
||||
Update:
|
||||
# Use auto update and builtin updater feature
|
||||
# This may cause problem https://github.com/LmeSzinc/AzurLaneAutoScript/issues/876
|
||||
EnableReload: true
|
||||
# Check update every X minute
|
||||
# [Disable] -1
|
||||
# [Default] 5
|
||||
|
@ -59,7 +59,6 @@ AddAlas:
|
||||
Update:
|
||||
UpToDate:
|
||||
HaveUpdate:
|
||||
UpdateFailed:
|
||||
UpdateStart:
|
||||
UpdateWait:
|
||||
UpdateRun:
|
||||
@ -74,6 +73,7 @@ Update:
|
||||
Time:
|
||||
Message:
|
||||
DisabledWarn:
|
||||
DetailedHistory:
|
||||
|
||||
Text:
|
||||
InvalidFeedBack:
|
@ -2002,11 +2002,11 @@
|
||||
"Update": {
|
||||
"UpToDate": "Latest version",
|
||||
"HaveUpdate": "A new version is available",
|
||||
"UpdateFailed": "Update failed. Logs can be found in ./log/*_gui.txt",
|
||||
"UpdateStart": "Start update",
|
||||
"UpdateWait": "Waiting for all alas complete current task",
|
||||
"UpdateRun": "Updating",
|
||||
"UpdateSuccess": "Update succeeded, restarting",
|
||||
"UpdateFailed": "Update failed. Logs can be found in ./log/*_gui.txt",
|
||||
"UpdateChecking": "Checking for updates",
|
||||
"UpdateCancel": "Update canceled, restarting Alas",
|
||||
"UpdateFinish": "Update succeeded, please restart manually",
|
||||
@ -2015,7 +2015,8 @@
|
||||
"Author": "Author",
|
||||
"Time": "Commit time",
|
||||
"Message": "Commit message",
|
||||
"DisabledWarn": "Updater module is disabled. You need to manually restart Alas to update"
|
||||
"DisabledWarn": "Updater module is disabled. You need to manually restart Alas to update",
|
||||
"DetailedHistory": "Detailed Commit History"
|
||||
},
|
||||
"Text": {
|
||||
"InvalidFeedBack": "Invalid format. Example: {0}"
|
||||
|
@ -2002,11 +2002,11 @@
|
||||
"Update": {
|
||||
"UpToDate": "Gui.Update.UpToDate",
|
||||
"HaveUpdate": "Gui.Update.HaveUpdate",
|
||||
"UpdateFailed": "Gui.Update.UpdateFailed",
|
||||
"UpdateStart": "Gui.Update.UpdateStart",
|
||||
"UpdateWait": "Gui.Update.UpdateWait",
|
||||
"UpdateRun": "Gui.Update.UpdateRun",
|
||||
"UpdateSuccess": "Gui.Update.UpdateSuccess",
|
||||
"UpdateFailed": "Gui.Update.UpdateFailed",
|
||||
"UpdateChecking": "Gui.Update.UpdateChecking",
|
||||
"UpdateCancel": "Gui.Update.UpdateCancel",
|
||||
"UpdateFinish": "Gui.Update.UpdateFinish",
|
||||
@ -2015,7 +2015,8 @@
|
||||
"Author": "Gui.Update.Author",
|
||||
"Time": "Gui.Update.Time",
|
||||
"Message": "Gui.Update.Message",
|
||||
"DisabledWarn": "Gui.Update.DisabledWarn"
|
||||
"DisabledWarn": "Gui.Update.DisabledWarn",
|
||||
"DetailedHistory": "Gui.Update.DetailedHistory"
|
||||
},
|
||||
"Text": {
|
||||
"InvalidFeedBack": "Gui.Text.InvalidFeedBack"
|
||||
|
@ -2002,11 +2002,11 @@
|
||||
"Update": {
|
||||
"UpToDate": "已是最新版本",
|
||||
"HaveUpdate": "有新版本可用",
|
||||
"UpdateFailed": "更新失败,可在./log/*_gui.txt中找到错误日志",
|
||||
"UpdateStart": "开始更新",
|
||||
"UpdateWait": "等待所有 Alas 完成当前任务",
|
||||
"UpdateRun": "更新中",
|
||||
"UpdateSuccess": "更新成功,正在重启",
|
||||
"UpdateFailed": "更新失败,可在./log/*_gui.txt中找到错误日志",
|
||||
"UpdateChecking": "检查更新中",
|
||||
"UpdateCancel": "取消更新,重启 Alas 中",
|
||||
"UpdateFinish": "更新成功,请手动重启",
|
||||
@ -2015,7 +2015,8 @@
|
||||
"Author": "作者",
|
||||
"Time": "提交时间",
|
||||
"Message": "提交信息",
|
||||
"DisabledWarn": "更新模块未启用,你需要手动重启 Alas 进行更新"
|
||||
"DisabledWarn": "更新模块未启用,你需要手动重启 Alas 进行更新",
|
||||
"DetailedHistory": "详细提交历史"
|
||||
},
|
||||
"Text": {
|
||||
"InvalidFeedBack": "格式错误。 示例:{0}"
|
||||
|
@ -2002,11 +2002,11 @@
|
||||
"Update": {
|
||||
"UpToDate": "已是最新版本",
|
||||
"HaveUpdate": "有新版本可用",
|
||||
"UpdateFailed": "更新失敗,可在./log/*_gui.txt中找到錯誤日誌",
|
||||
"UpdateStart": "開始更新",
|
||||
"UpdateWait": "等待所有 Alas 完成當前任務",
|
||||
"UpdateRun": "更新中",
|
||||
"UpdateSuccess": "更新成功,正在重啓",
|
||||
"UpdateFailed": "更新失敗,可在./log/*_gui.txt中找到錯誤日誌",
|
||||
"UpdateChecking": "檢查更新中",
|
||||
"UpdateCancel": "取消更新,重啓 Alas 中",
|
||||
"UpdateFinish": "更新成功,請手動重啓",
|
||||
@ -2015,7 +2015,8 @@
|
||||
"Author": "作者",
|
||||
"Time": "提交時間",
|
||||
"Message": "提交資訊",
|
||||
"DisabledWarn": "更新模塊未啟用,你需要手動重啓 Alas 進行更新"
|
||||
"DisabledWarn": "更新模塊未啟用,你需要手動重啓 Alas 進行更新",
|
||||
"DetailedHistory": "詳細提交歷史"
|
||||
},
|
||||
"Text": {
|
||||
"InvalidFeedBack": "格式錯誤。 示例:{0}"
|
||||
|
@ -422,14 +422,14 @@ class AlasGUI(Frame):
|
||||
# update Emotion Record if Emotion Value is changed
|
||||
if 'Emotion' in k and 'Value' in k:
|
||||
k = k.split('.')
|
||||
k[-1] = k[-1].replace('Value','Record')
|
||||
k[-1] = k[-1].replace('Value', 'Record')
|
||||
k = '.'.join(k)
|
||||
v = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
|
||||
modified[k] = v
|
||||
deep_set(config, k, v)
|
||||
valid.append(self.path_to_idx[k])
|
||||
pin[self.path_to_idx[k]] = v
|
||||
|
||||
|
||||
else:
|
||||
modified.pop(k)
|
||||
invalid.append(self.path_to_idx[k])
|
||||
@ -637,7 +637,7 @@ class AlasGUI(Frame):
|
||||
onclick=_force_restart,
|
||||
color="menu",
|
||||
).style(f'--menu-Restart--')
|
||||
|
||||
|
||||
def dev_translate(self) -> None:
|
||||
go_app("translate", new_window=True)
|
||||
lang.TRANSLATE_MODE = True
|
||||
@ -678,6 +678,21 @@ class AlasGUI(Frame):
|
||||
t("Gui.Update.Message"),
|
||||
],
|
||||
)
|
||||
with use_scope("updater_detail", clear=True):
|
||||
put_text(t("Gui.Update.DetailedHistory"))
|
||||
history = updater.get_commit(
|
||||
f"origin/{updater.Branch}", n=20, short_sha1=True)
|
||||
put_table(
|
||||
[
|
||||
commit for commit in history
|
||||
],
|
||||
header=[
|
||||
"SHA1",
|
||||
t("Gui.Update.Author"),
|
||||
t("Gui.Update.Time"),
|
||||
t("Gui.Update.Message"),
|
||||
],
|
||||
)
|
||||
|
||||
def u(state):
|
||||
if state == -1:
|
||||
|
Loading…
Reference in New Issue
Block a user