Co-authored-by: sigonasr2 <sigonasr2@gmail.com>main
parent
3125dcbfe6
commit
cc0f69d8b1
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,17 @@ |
|||||||
|
#Builds a runnable jar file using ${MAIN_CLASS} as an entry point and then runs the newly generated jar. |
||||||
|
#Java |
||||||
|
source ${LANGUAGE}/scripts/version_info |
||||||
|
rm -Rf bin/* |
||||||
|
javac -d bin *.java |
||||||
|
printf "\n\n\nGenerating Manifest...\n\n" |
||||||
|
touch manifest |
||||||
|
echo "Main-Class: ${MAIN_CLASS}" > manifest |
||||||
|
printf "\n\n\nCreating Jar...\n\n" |
||||||
|
ORIGINAL_LOC=$(pwd) |
||||||
|
cd ${OUT_DIR} |
||||||
|
jar cfm ${PROJECT_NAME}.jar ${ORIGINAL_LOC}/manifest . |
||||||
|
jar uf ${PROJECT_NAME}.jar -C ../lib/bin/ . |
||||||
|
printf "\n\n\nRunning Program...\n\n" |
||||||
|
mv sigPlace.jar .. |
||||||
|
cd .. |
||||||
|
java ${CUSTOM_PARAMS} -Djava.library.path="${LIBRARY_PATH}" -jar ${PROJECT_NAME}.jar "$@" |
@ -1,12 +1,14 @@ |
|||||||
if [ -z "$1" ] |
export AUTO_UPDATE=true |
||||||
then |
|
||||||
echo "" |
source utils/define.sh |
||||||
echo " Usage: ./sig <command> {args}" |
|
||||||
echo "" |
define PROJECT_NAME "sigPlace" |
||||||
echo " Command List:" |
define PROJECT_DIR "." |
||||||
ls -1 ./scripts | sed -e 's/\.sh$//' | sed -e 's/^/ /' |
define MAIN_CLASS "${PROJECT_NAME}" |
||||||
echo "" |
define OUT_DIR "bin" |
||||||
exit |
define LIBRARY_PATH "lib" |
||||||
fi |
define CLASS_PATH "${PROJECT_DIR}" |
||||||
|
define CUSTOM_PARAMS "" |
||||||
|
define LANGUAGE "Java" |
||||||
|
|
||||||
./scripts/$1.sh "${*:2}" |
./scripts/$1.sh "${*:2}" |
Binary file not shown.
@ -0,0 +1,9 @@ |
|||||||
|
export VARS=("") |
||||||
|
|
||||||
|
export LANGUAGE="" |
||||||
|
|
||||||
|
function define() { |
||||||
|
VARS+=("$1") |
||||||
|
value="${*:2}" |
||||||
|
eval export "$1"='$value' |
||||||
|
} |
Loading…
Reference in new issue