Maven 如何更改批处理文件中的目录?
我有一个如下的批处理文件Maven 如何更改批处理文件中的目录?,maven,batch-file,Maven,Batch File,我有一个如下的批处理文件 E: cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\core mvn clean install cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\handset mvn clean install 它将为core运行mvn install命令 但它不会为手持设备项目执行mvn install命令。尝试如下
E:
cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\core
mvn clean install
cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\handset
mvn clean install
它将为core运行mvn install
命令
但它不会为手持设备项目执行mvn install
命令。尝试如下操作:
pushd "E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\core"
mvn clean install
popd
pushd "cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\handset"
mvn clean install
popd
这是更改驱动器和文件夹的另一种方法 如果mvn是批处理文件,
call
命令用于解决该问题
cd /d "E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\core"
call mvn clean install
cd /d "cd E:\cvs-projects-command\customers\prd_mno_nfc_wallet\server\handset"
call mvn clean install
mvn必须同时存在于这两个文件夹中才能运行。手机文件夹中是否存在mvn?是批处理文件吗?