]> git.mxchange.org Git - jfinancials-lib.git/blobdiff - dist.sh
Continued:
[jfinancials-lib.git] / dist.sh
diff --git a/dist.sh b/dist.sh
new file mode 100755 (executable)
index 0000000..f48251e
--- /dev/null
+++ b/dist.sh
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+NAME="${PWD##*/}"
+DIST="dist/${NAME}.jar"
+LIST=`find ../*/lib/${NAME}.jar`
+LIST="${LIST} `find ../*/*-ejb/lib/${NAME}.jar`"
+LIST="${LIST} ${HOME}/gf_domains/domain1/lib/"
+
+for target in ${LIST};
+do
+       if [ ! -f "${DIST}" ]
+       then
+               echo "$0: '${DIST}' not found."
+       elif [ -d "${target}" ]
+       then
+               cp -v "${DIST}" "${target}"
+       elif [ -f "${target}" ]
+       then
+               cp -v "${DIST}" "${target}"
+       else
+               echo "$0: Target '${target}' not found."
+       fi
+done