From cbdc927c3c401e81ca3e8a3cb875820efac27513 Mon Sep 17 00:00:00 2001 From: Michal Cmarada Date: Fri, 1 Mar 2019 13:44:47 +0100 Subject: automate Jars installation script Enables to install all plugins no matter what will be added in future. When the plugin preserves the naming schema (jvpp-[name]-[version].jar) it will be automatically detected by the script and Jars will be installed in local maven repository Change-Id: I07e7585d182653de53c716e36b8bcf5e475cdcd4 Signed-off-by: Michal Cmarada --- scripts/install_jvpp.sh | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'scripts') diff --git a/scripts/install_jvpp.sh b/scripts/install_jvpp.sh index 7c53a1b..bfaec42 100755 --- a/scripts/install_jvpp.sh +++ b/scripts/install_jvpp.sh @@ -35,15 +35,12 @@ echo "Maven artifacts version:" ${VERSION} cd "$dir/../java/" -echo "Installing jars to Maven:" -mvn install:install-file -Dfile=jvpp-registry-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-registry -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-core-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-core -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-ioampot-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-ioampot -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-ioamtrace-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-ioamtrace -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-ioamexport-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-ioamexport -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-nat-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-nat -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-nsh-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-nsh -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-acl-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-acl -Dversion=${VERSION} -Dpackaging=jar -mvn install:install-file -Dfile=jvpp-ikev2-${MAIN_VER}.jar -DgroupId=io.fd.vpp -DartifactId=jvpp-ikev2 -Dversion=${VERSION} -Dpackaging=jar +JARS=`find . -name "jvpp*.jar" | sed -e "s/.\///" -e "s/-.[0-9].*.jar//"` + +for JAR in ${JARS} +do + echo "Installing ${JAR} to local maven." + mvn install:install-file -Dfile=${JAR}-${MAIN_VER}.jar -DgroupId=io.fd.jvpp -DartifactId=${JAR} -Dversion=${VERSION} -Dpackaging=jar +done echo "all done." -- cgit 1.2.3-korg