From 6b1d7b17d408f4ec945c264e60d26d134379e233 Mon Sep 17 00:00:00 2001 From: hanhh Date: Sun, 6 Jun 2021 15:30:14 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=89=88=E6=9C=AC=E5=8F=B7?= =?UTF-8?q?=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- shell/update.sh | 1 + src/layouts/index.tsx | 12 +++++++++++- src/version.ts | 2 ++ 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 src/version.ts diff --git a/shell/update.sh b/shell/update.sh index abbc8907..64301d4c 100755 --- a/shell/update.sh +++ b/shell/update.sh @@ -205,6 +205,7 @@ update_raw() { ) cron_name=$(grep "new Env" $raw_file_name | awk -F "\(" '{print $2}' | awk -F "\)" '{print $1}' | sed 's:^.\(.*\).$:\1:' | head -1) [[ -z $cron_name ]] && cron_name="$raw_file_name" + [[ -z $cron_line ]] && cron_line=$(grep "cron:" $raw_file_name | awk -F ":" '{print $2}' | xargs) [[ -z $cron_line ]] && cron_line="0 6 * * *" if [[ -z $cron_id ]]; then result=$(add_cron_api "$cron_line:$cmd_task $filename:$cron_name") diff --git a/src/layouts/index.tsx b/src/layouts/index.tsx index c855ba92..a8853dd1 100644 --- a/src/layouts/index.tsx +++ b/src/layouts/index.tsx @@ -14,6 +14,7 @@ import 'codemirror/mode/shell/shell.js'; import { request } from '@/utils/http'; import './index.less'; import vhCheck from 'vh-check'; +import { version, changeLog } from '../version'; export default function (props: any) { const logout = () => { @@ -63,7 +64,16 @@ export default function (props: any) { return ( + 控制面板 + + + {version} + + + + } menuItemRender={(menuItemProps: any, defaultDom: any) => { if ( menuItemProps.isUrl || diff --git a/src/version.ts b/src/version.ts new file mode 100644 index 00000000..6c551271 --- /dev/null +++ b/src/version.ts @@ -0,0 +1,2 @@ +export const version = 'v2.0.0-111'; +export const changeLog = 'https://t.me/jiaolongwang/101';