diff --git a/ci/create-release.sh b/ci/create-release.sh index f50f4e7848feb2ef104d06366afbfe364926eb32..6ca37e5232ae70da80109ecfc484092fd4263e33 100755 --- a/ci/create-release.sh +++ b/ci/create-release.sh @@ -39,4 +39,12 @@ popd rm -rf xtext-merge # let's copy the scripts to the correct location -cp ../src/release/* . +mkdir bin + +for NAME in $RELEASE_PLUGINS; do + echo "Copying scripts of plugin $NAME" + + if [ -e src/core/de.evoal.$NAME/scripts ]; then + cp -r src/core/de.evoal.$NAME/scripts/* bin + fi +done \ No newline at end of file diff --git a/src/core/de.evoal.core.arff/scripts/run-arff-to-ddl.sh b/src/core/de.evoal.core.arff/scripts/run-arff-to-ddl.sh new file mode 100755 index 0000000000000000000000000000000000000000..7340a40e07aa1e0efb09d8e76a9f8395eb1ea1b1 --- /dev/null +++ b/src/core/de.evoal.core.arff/scripts/run-arff-to-ddl.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +source paths.env + +if [ "$#" -ne 3 ]; then + echo "Usage: $0 <execution-folder> <input.arff> <output.ddl>" + exit 1 +fi + +cd $1 + +set -x +java -Dorg.jboss.logging.provider=slf4j\ + --module-path "${EVOALPATH}/modules/:$PLUGIN_PATHS" \ + --add-modules ALL-MODULE-PATH \ + --add-opens java.base/java.lang=guice \ + -m de.evoal.core/de.evoal.core.main.Evoal \ + -Bcore:main=extract-data-definition-from-arff \ + -Barff:input=$2 \ + -Barff:output=$3 diff --git a/src/core/de.evoal.core/scripts/paths.env b/src/core/de.evoal.core/scripts/paths.env new file mode 100644 index 0000000000000000000000000000000000000000..a5824f56fa6131dafd9adfd135daa1a360303944 --- /dev/null +++ b/src/core/de.evoal.core/scripts/paths.env @@ -0,0 +1,2 @@ +EVOALPATH="$( cd -- "$(dirname "$0/..")" >/dev/null 2>&1 ; pwd -P )" +PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` diff --git a/src/release/run-search.sh b/src/core/de.evoal.core/scripts/run-search.sh similarity index 85% rename from src/release/run-search.sh rename to src/core/de.evoal.core/scripts/run-search.sh index dc5df848cdcc209964761a93f8397c13cf709380..3356f39630bf62f60655bc2146521713c50a40bc 100755 --- a/src/release/run-search.sh +++ b/src/core/de.evoal.core/scripts/run-search.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 3 ]; then echo "Usage: $0 <execution-folder> <eal-file> <output-folder>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ --module-path "${EVOALPATH}/modules/:$PLUGIN_PATHS" \ diff --git a/src/release/debug-generator.sh b/src/core/de.evoal.generator.main/scripts/debug-generator.sh similarity index 79% rename from src/release/debug-generator.sh rename to src/core/de.evoal.generator.main/scripts/debug-generator.sh index 9155fdb36f231794636f1156126d647a24facc75..b03ec59ac4e5ff06d51d09432b76bdb479f458a5 100755 --- a/src/release/debug-generator.sh +++ b/src/core/de.evoal.generator.main/scripts/debug-generator.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 2 ]; then echo "Usage: $0 <execution-folder> <generator-file>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ -agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=1044\ diff --git a/src/release/run-generator.sh b/src/core/de.evoal.generator.main/scripts/run-generator.sh similarity index 77% rename from src/release/run-generator.sh rename to src/core/de.evoal.generator.main/scripts/run-generator.sh index b79476d48f550c7e92a367880f7e5e13fb7d3046..ea70931a50b75e5c8715165013a1d3e8ba927e76 100755 --- a/src/release/run-generator.sh +++ b/src/core/de.evoal.generator.main/scripts/run-generator.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 2 ]; then echo "Usage: $0 <execution-folder> <generator-file>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ --module-path "${EVOALPATH}/modules/:$PLUGIN_PATHS" \ diff --git a/src/release/debug-search-with-surrogate.sh b/src/core/de.evoal.surrogate.api/scripts/debug-search-with-surrogate.sh similarity index 88% rename from src/release/debug-search-with-surrogate.sh rename to src/core/de.evoal.surrogate.api/scripts/debug-search-with-surrogate.sh index fb93028c5ddaa434dda3dc4a0c9095986a6e8154..3e0ea934f9aad8e766af9212c8a0029793666890 100755 --- a/src/release/debug-search-with-surrogate.sh +++ b/src/core/de.evoal.surrogate.api/scripts/debug-search-with-surrogate.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 7 ]; then echo "Usage: $0 <execution-folder> <ea-file> <mll-file> <pre-trained.pson> <training-points.json> <output> <constraint-folder>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ -agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=1044\ diff --git a/src/release/debug-training.sh b/src/core/de.evoal.surrogate.api/scripts/debug-training.sh similarity index 79% rename from src/release/debug-training.sh rename to src/core/de.evoal.surrogate.api/scripts/debug-training.sh index 86a8aa51850f2c05a429ef08a13bc3422b0811e7..e6a24e510dead864ce3256af51c4da7f98b4c4aa 100755 --- a/src/release/debug-training.sh +++ b/src/core/de.evoal.surrogate.api/scripts/debug-training.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 2 ]; then echo "Usage: $0 <execution-folder> <mll-file>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ -agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=1044\ diff --git a/src/release/run-search-with-surrogate.sh b/src/core/de.evoal.surrogate.api/scripts/run-search-with-surrogate.sh similarity index 88% rename from src/release/run-search-with-surrogate.sh rename to src/core/de.evoal.surrogate.api/scripts/run-search-with-surrogate.sh index 10abbeab062b7b7b354016857498398bd7e3f629..b1cafeb9275ef3f2be3fa35f644d7948eddc9290 100755 --- a/src/release/run-search-with-surrogate.sh +++ b/src/core/de.evoal.surrogate.api/scripts/run-search-with-surrogate.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 7 ]; then echo "Usage: $0 <execution-folder> <ea-file> <mll-file> <pre-trained.pson> <training-points.json> <output> <constraint-folder>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ --module-path "${EVOALPATH}/modules/:$PLUGIN_PATHS" \ diff --git a/src/release/run-training.sh b/src/core/de.evoal.surrogate.api/scripts/run-training.sh similarity index 77% rename from src/release/run-training.sh rename to src/core/de.evoal.surrogate.api/scripts/run-training.sh index 0e88fe7625c39689219901e52f5b7b7609e17d4c..7c8572e85b1e369fda03607cad48e1e09753b482 100755 --- a/src/release/run-training.sh +++ b/src/core/de.evoal.surrogate.api/scripts/run-training.sh @@ -1,16 +1,14 @@ #!/bin/bash +source paths.env + if [ "$#" -ne 2 ]; then echo "Usage: $0 <execution-folder> <mll-file>" exit 1 fi -EVOALPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" - cd $1 -PLUGIN_PATHS=`ls -d "${EVOALPATH}/plugins"/* | tr '\n' ':'` - set -x java -Dorg.jboss.logging.provider=slf4j\ --module-path "${EVOALPATH}/modules/:$PLUGIN_PATHS" \