deploy.js

This commit is contained in:
321zhangjvzhi 2024-03-31 13:37:12 +08:00
parent 6c17f453a8
commit 69b789b546
5 changed files with 5 additions and 4 deletions

1
.gitignore vendored
View File

@ -50,3 +50,4 @@ pnpm*
#components.d.ts #components.d.ts
stats.html stats.html
ts-out-dir ts-out-dir
archive.zip

View File

@ -105,10 +105,10 @@ async function main() {
// await exec(`unzip -O gbk ${archivePath} -d ${target}`) // await exec(`unzip -O gbk ${archivePath} -d ${target}`)
//} else { //} else {
await exec(`unzip ${archivePath} -d ${target}`) await exec(`unzip ${archivePath} -d ${target}`)
await exec(`mv ${target}/dist ${target}/iGame`) await exec(`mv ${target}/dist ${target}/home`)
//} //}
const nginxTarget = '/home/lolosia/nginx/home' const nginxTarget = '/home/lolosia/nginx'
console.log('移除旧目录 ...') console.log('移除旧目录 ...')
await sudo(`rm -rf ${nginxTarget}/${nginxContentPath}`) await sudo(`rm -rf ${nginxTarget}/${nginxContentPath}`)

View File

@ -19,6 +19,7 @@
"vitest": "vitest --ui", "vitest": "vitest --ui",
"tsc-check": "tsc", "tsc-check": "tsc",
"coverage": "vitest run --coverage", "coverage": "vitest run --coverage",
"deploy": "node deploy.js",
"preinstall": "only-allow pnpm" "preinstall": "only-allow pnpm"
}, },
"dependencies": { "dependencies": {

View File

@ -87,7 +87,7 @@ export const settings: SettingsConfig = {
/* /*
* vite.config.js base config * vite.config.js base config
* */ * */
viteBasePath: '/vue-admin-plus/', viteBasePath: '/home/',
/* /*
* i18n setting default language * i18n setting default language

View File

@ -8,7 +8,6 @@ export {}
declare module 'vue' { declare module 'vue' {
export interface GlobalComponents { export interface GlobalComponents {
AppPage: typeof import('./../src/components/AppPage.vue')['default'] AppPage: typeof import('./../src/components/AppPage.vue')['default']
Container: typeof import('@/components/AppPage.vue')['default']
ElSvgIcon: typeof import('./../src/components/ElSvgIcon.vue')['default'] ElSvgIcon: typeof import('./../src/components/ElSvgIcon.vue')['default']
IconSelector: typeof import('./../src/components/IconSelector.vue')['default'] IconSelector: typeof import('./../src/components/IconSelector.vue')['default']
MenuIcon: typeof import('./../src/components/MenuIcon.vue')['default'] MenuIcon: typeof import('./../src/components/MenuIcon.vue')['default']