当前位置:网站首页>bat 批处理单独环境打包
bat 批处理单独环境打包
2022-06-11 08:15:00 【王家五哥】
利用批处理+maven 区分不同环境的项目打包
@echo off
color 0a
title MAVEN项目一键提取war
rem 多jdk可以打开指定版本
rem SET JAVA_HOME=C:\Program Files\Java\jdk1.8.0_101
SET "TARGET_HOME=C:\Users\wll\Desktop\temp_data"
SET "PROECT_HOME=D:\A_eclipse_work\gitlab\gitlab-fulan\inc\gwcslife-incVer_14_0_0_0"
echo.
echo ---------------------------请输入要打包的环境,回车即可!---------------------------
echo ---------------------------请输入要打包的环境,回车即可!---------------------------
echo.
ECHO.
ECHO. [1] sit
ECHO. [2] dev
ECHO. [3] uat
ECHO. [4] prod
ECHO. [5] 退 出
ECHO.
ECHO.请输入选择项目的序号:
set /p ID=
IF "%id%"=="1" GOTO sit
IF "%id%"=="2" GOTO dev
IF "%id%"=="3" GOTO uat
IF "%id%"=="4" GOTO prod
IF "%id%"=="5" EXIT
PAUSE
:sit
SET "PROECT_EVN= -P sit"
goto:run
:dev
SET "PROECT_EVN= -P dev"
goto:run
:uat
SET "PROECT_EVN= -P uat"
goto:run
:prod
SET "PROECT_EVN= -P prod"
goto:run
:run
echo.
echo ---------------------------数据处理中!请勿关闭!---------------------------
echo ---------------------------数据处理中!请勿关闭!---------------------------
echo.
cd /d "%TARGET_HOME%"
if exist "recr.war" (
del /s /Q "recr.war"
)
if exist "extra.war" (
del /s /Q "extra.war"
)
cd /d "%PROECT_HOME%"
call mvn clean install %PROECT_EVN%
echo.
echo ---------------------------business正在进行数据拷贝...---------------------------
echo.
copy %PROECT_HOME%\inc-business\target\*.war %TARGET_HOME%
echo.
echo ---------------------------business正在数据拷贝完成...---------------------------
echo.
echo.
echo ---------------------------inc-extra正在进行数据拷贝...---------------------------
echo.
copy %PROECT_HOME%\inc-extra\target\*.war %TARGET_HOME%
echo.
echo ---------------------------inc-extra正在数据拷贝完成...---------------------------
echo.
echo.
echo ---------------------------项目打包完成!!!---------------------------
TIMEOUT /T 20
pause边栏推荐
猜你喜欢

Tutoriel de démarrage bladed (vidéo)

Alchemy experience (model training of deep learning) the necessity of timely adjusting training parameters for some situations (the adjustment of learning rate LR is the primary) summarizes some metho

Study the Analects of entanglement

Magnifying mirror rendering

【1】 Integrated learning: quickly understand Integrated Learning
![[the most complete ENSP [installation diagram] in history!]](/img/1a/7d50d6e5c06a5e3ce6acab16ddb638.jpg)
[the most complete ENSP [installation diagram] in history!]

学习《缠解论语》

Return in foreach and break in for

记一次忽略@SuppressLint(“NewApi“)提示引发的血案

Jupyter notebook code completion plug-in + Solution
随机推荐
Typescript null and undefined
Training yolov4 CSP model using coco dataset
(resolved) pychart debug error -unicode decodeerror: 'UTF-8' codec can't decode byte 0xe8 in position 1023
Shell编程笔记
Jupyter notebook code completion plug-in + Solution
TypeScript-命名空间
TypeScript-头文件使用细节
Printing diamond of beginner C
Summary of embedded software interview questions
Typescript keyboard mapping
860. lemonade change
torch. roll
Image data enhancement (translation, rotation, brightness transformation, flipping, adding Gaussian noise, scaling, cropping)
Anaconda+tensorflow most effective summary version (blood and tears summary of 6 reloads)
嵌入式软件面试问题总结
[transfer] two-way merging and sorting of C language
Servlet、ServletConfig、ServletContext
Summary of evaluation index knowledge points in target detection: summary of IOU cross overlap unit and map/ap/tp/fp/np
AttributeError: module ‘tensorflow. compat. v2.__ internal__‘ has no attribute ‘register_ clear_ session_
Crawl Baidu Baipin dynamic page