![Board logo](images/default/logo.gif)
标题: [问题求助] 求教sh转bat [打印本页]
作者: zf0512305 时间: 2013-4-22 09:18 标题: 求教sh转bat
#! /bin/bash
function install_file {
file=$1
group_id=$2
artifact_id=$3
version=$4
mvn install:install-file \
-Dfile=$file \
-DgroupId=$group_id \
-DartifactId=$artifact_id \
-Dversion=$version \
-Dpackaging=jar \
-DcreateChecksum=true
}
install_file \
'lib/ADLParser-2009.jar' \
'com.bjtxx' \
'ADLParser' \
'2009'
install_file \
'lib/apache-commons-id-2009.jar' \
'com.bjtxx' \
'apache-commons-id' \
'2009'
install_file \
'lib/gwt2swf-0.6.0.jar' \
'com.bjtxx' \
'gwt2swf' \
'0.6.0'
exit
求各位大神帮忙,万分感谢
作者: Batcher 时间: 2013-4-22 10:31
- @echo off
- call install_file "lib/ADLParser-2009.jar" "com.bjtxx" "ADLParser" "2009"
- call install_file "lib/apache-commons-id-2009.jar" "com.bjtxx" "apache-commons-id" "2009"
- call install_file "lib/gwt2swf-0.6.0.jar" "com.bjtxx" "gwt2swf" "0.6.0"
-
- :install_file
- file=%1
- group_id=%2
- artifact_id=%3
- version=%4
- mvn install:install-file -Dfile=%file% -DgroupId=%group_id% -DartifactId=%artifact_id% -Dversion=%version% -Dpackaging=jar -DcreateChecksum=true
复制代码
欢迎光临 批处理之家 (http://bathome.net./) |
Powered by Discuz! 7.2 |