cvpilot-tool/apps/desktop/electron/core/initial.ts

19 lines
409 B
TypeScript
Raw Normal View History

2024-10-13 10:10:05 +08:00
import { app } from "electron";
import { mkdirSync } from "fs";
import path from "path";
const root = app.getPath("userData");
/**
*
*/
export const pluginPath = path.join(root, "plugin");
/**
*
*/
export const modelPath = path.join(root, "model");
export const initialize = () => {
mkdirSync(pluginPath, { recursive: true });
mkdirSync(modelPath, { recursive: true });
};