From e6c2d30cbae828ff8ead426e69dace01bcde330f Mon Sep 17 00:00:00 2001 From: panjia Date: Thu, 4 Jan 2024 15:48:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8F=91=E5=B8=83=E7=9B=AE?= =?UTF-8?q?=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 500标准.VUE/9.published/建立D盘目录.bat | 51 +++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 500标准.VUE/9.published/建立D盘目录.bat diff --git a/500标准.VUE/9.published/建立D盘目录.bat b/500标准.VUE/9.published/建立D盘目录.bat new file mode 100644 index 0000000..f330384 --- /dev/null +++ b/500标准.VUE/9.published/建立D盘目录.bat @@ -0,0 +1,51 @@ +@ECHO OFF +setlocal EnableDelayedExpansion +cd /d %~dp0 +::当前目录 +set rootPath=%cd% +cd .. +::数据库目录 +set dataPath=%cd%\2.database +echo %dataPath% + +::::::::::::::::: +set publishedPath=D:\SATLIC.CLOUD.TEST +::::::::::::::::: + +::权限检查 +net.exe session 1>NUL 2>NUL && ( + goto as_admin +) || ( + goto not_admin +) + + + +:as_admin +if not exist %publishedPath% md %publishedPath% + +::切换目录 +cd /d %publishedPath% + +::建立数据库 +set dname=database +set dfile2=%publishedPath%\%dname% +if not exist %dfile2% mklink /d %dname% %dataPath% + +::程序:1 +set dname=程序1名称 +set dfile2=%publishedPath%\%dname% +if exist %rootPath%\%dname% ( + echo %rootPath%\%dname% + if not exist %dfile2% mklink /d %dname% %rootPath%\%dname% +) + +echo success ... +goto end + +:not_admin +echo not as admin + +:end +ping 127.0.0.1 -n 3 >nul +exit \ No newline at end of file