|
@@ -1,4 +1,4 @@
|
|
|
-import { writeFileSync } from "fs";
|
|
|
+import { writeFileSync, existsSync } from "fs";
|
|
|
import { execSync } from "child_process";
|
|
|
import moment from "moment";
|
|
|
import packageJson from "./package.json" assert { type: "json" };
|
|
@@ -24,4 +24,22 @@ VITE_GIT_REPO_VERSION=${revision}
|
|
|
`
|
|
|
);
|
|
|
|
|
|
+// 如果不存在则创建,对真正的构建无影响
|
|
|
+if (!existsSync("./src/devLoginParams.ts")) {
|
|
|
+ writeFileSync(
|
|
|
+ "./src/devLoginParams.ts",
|
|
|
+ `
|
|
|
+ export const isAdmin = false;
|
|
|
+ export let forceChange = false;
|
|
|
+ forceChange = true;
|
|
|
+
|
|
|
+ // 很多任务,选分组2
|
|
|
+ export const loginName = "";
|
|
|
+ export const password = "";
|
|
|
+ export const examId = "";
|
|
|
+ export const markerId = "";
|
|
|
+ `
|
|
|
+ );
|
|
|
+}
|
|
|
+
|
|
|
console.log();
|