sh wso2 studio developer artifact.xml生成器

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh wso2 studio developer artifact.xml生成器相关的知识,希望对你有一定的参考价值。

#!/bin/bash
# using: bash-artifactxml-gen.sh my.project.folder
#
ROOTFOLDER=$*
#set src dir
SRCDIR=$ROOTFOLDER'/src/';
#cd to src dir
cd $SRCDIR;
#start gen artifact.xml
echo '<?xml version="1.0" encoding="UTF-8"?><artifacts>';
#foreach all xml (except pom.xml and artifact.xml) files in src directory
for D in `find . -name '*.xml' ! -name 'pom.xml' ! -name 'artifact.xml'`
do
	#set full filename
	FILENAME=`echo $D | awk 'BEGIN { RS = "/" }; END {print $1}'`;
	#set foldername
	FOLDERNAME=`echo $D | awk 'BEGIN { FS = "/" }; END {print $4}'`;
	#set filename whitout extension .xml
	FNAME=`echo $FILENAME | awk 'BEGIN {FS = ".xml"}; END {print $1}'`;
  #replace dot and slash in filepath
	PATHTOXML=`echo $D | sed 's/^.\///g'`;
	#set type
	TYPE=`echo $FOLDERNAME | sed 's/local-entries/local-entry/g;s/proxy-services/proxy-service/g;s/sequences/sequence/g;s/endpoints/endpoint/g;'`
	#out each artifact string
	echo '<artifact name="'$FNAME'" groupId="com.example.'$ROOTFOLDER'" version="1.0.0" type="synapse/'$TYPE'" serverRole="EnterpriseServiceBus">
        <file>src/'$PATHTOXML'</file>
    </artifact>'
done
#hmm seems really done
echo '</artifacts>';
#now just copy-paste

以上是关于sh wso2 studio developer artifact.xml生成器的主要内容,如果未能解决你的问题,请参考以下文章

android studio导入android系统源码 development/tools/idegen/idegen.sh执行报错

android studio导入android系统源码 development/tools/idegen/idegen.sh执行报错

android studio导入android系统源码 development/tools/idegen/idegen.sh执行报错

android studio导入android系统源码 development/tools/idegen/idegen.sh执行报错

sh 用于配置WSO2 EMM的脚本

1. Android Studio阅读源码