From 84d798c01fc07690a233cda8619fbdf6bad490f0 Mon Sep 17 00:00:00 2001 From: yuetsh <517252939@qq.com> Date: Fri, 5 Sep 2025 11:00:55 +0800 Subject: [PATCH] use rsbuild instead of vite --- .env | 8 +- .env.production | 8 +- .env.staging | 10 +- index.html | 3 +- package-lock.json | 2145 ++++++++++++--------- package.json | 16 +- rsbuild.config.ts | 93 + src/admin/api.ts | 2 +- src/admin/setting/config.vue | 2 +- src/admin/tutorial/components/Actions.vue | 2 +- src/admin/tutorial/detail.vue | 6 +- src/env.d.ts | 13 + src/main.ts | 4 +- src/oj/api.ts | 2 +- src/oj/problem/components/Form.vue | 4 +- src/shims.d.ts | 5 - src/utils/judge.ts | 2 +- src/utils/types.ts | 4 +- src/vite-env.d.ts | 13 - tsconfig.node.json | 2 +- vite.config.ts | 96 - 21 files changed, 1342 insertions(+), 1098 deletions(-) create mode 100644 rsbuild.config.ts create mode 100644 src/env.d.ts delete mode 100644 src/shims.d.ts delete mode 100644 src/vite-env.d.ts delete mode 100644 vite.config.ts diff --git a/.env b/.env index 226574f..46d87e9 100644 --- a/.env +++ b/.env @@ -1,4 +1,4 @@ -VITE_MAXKB_URL=https://maxkb.xuyue.cc/chat/api/embed?protocol=https&host=maxkb.xuyue.cc&token=2e801f7d6efdcc99 -VITE_OJ_URL=http://localhost:8000 -VITE_CODE_URL=https://code.xuyue.cc -VITE_JUDGE0_URL=https://judge0api.xuyue.cc \ No newline at end of file +PUBLIC_MAXKB_URL=https://maxkb.xuyue.cc/chat/api/embed?protocol=https&host=maxkb.xuyue.cc&token=2e801f7d6efdcc99 +PUBLIC_OJ_URL=http://localhost:8000 +PUBLIC_CODE_URL=https://code.xuyue.cc +PUBLIC_JUDGE0_URL=https://judge0api.xuyue.cc \ No newline at end of file diff --git a/.env.production b/.env.production index 5c19f06..0f9adab 100644 --- a/.env.production +++ b/.env.production @@ -1,4 +1,4 @@ -VITE_MAXKB_URL=https://maxkb.xuyue.cc/chat/api/embed?protocol=https&host=maxkb.xuyue.cc&token=2e801f7d6efdcc99 -VITE_OJ_URL=https://oj.xuyue.cc -VITE_CODE_URL=https://code.xuyue.cc -VITE_JUDGE0_URL=https://judge0api.xuyue.cc \ No newline at end of file +PUBLIC_MAXKB_URL=https://maxkb.xuyue.cc/chat/api/embed?protocol=https&host=maxkb.xuyue.cc&token=2e801f7d6efdcc99 +PUBLIC_OJ_URL=https://oj.xuyue.cc +PUBLIC_CODE_URL=https://code.xuyue.cc +PUBLIC_JUDGE0_URL=https://judge0api.xuyue.cc \ No newline at end of file diff --git a/.env.staging b/.env.staging index 71ec151..76547dd 100644 --- a/.env.staging +++ b/.env.staging @@ -1,5 +1,5 @@ -VITE_MAXKB_URL=http://10.13.114.114:92/chat/api/embed?protocol=http&host=10.13.114.114:92&token=dd37457027c40b39 -VITE_OJ_URL=http://10.13.114.114:81 -VITE_CODE_URL=http://10.13.114.114:82 -VITE_JUDGE0_URL=http://10.13.114.114:8082 -VITE_ICONIFY_URL=http://10.13.114.114:8098 \ No newline at end of file +PUBLIC_MAXKB_URL=http://10.13.114.114:92/chat/api/embed?protocol=http&host=10.13.114.114:92&token=dd37457027c40b39 +PUBLIC_OJ_URL=http://10.13.114.114:81 +PUBLIC_CODE_URL=http://10.13.114.114:82 +PUBLIC_JUDGE0_URL=http://10.13.114.114:8082 +PUBLIC_ICONIFY_URL=http://10.13.114.114:8098 \ No newline at end of file diff --git a/index.html b/index.html index 4ce5be8..85770d8 100644 --- a/index.html +++ b/index.html @@ -12,11 +12,10 @@
-