summaryrefslogtreecommitdiffstats
path: root/run.sh
diff options
context:
space:
mode:
Diffstat (limited to 'run.sh')
-rw-r--r--run.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/run.sh b/run.sh
new file mode 100644
index 0000000..55f1094
--- /dev/null
+++ b/run.sh
@@ -0,0 +1,12 @@
1#!/bin/bash
2
3# clean up
4rm -rf bin && mkdir bin
5
6# run the app if compilation succeeded
7if javac -d "bin/classes" -cp "lib/*" src/main/java/com/example/App.java; then
8 echo "--- Running Application ---"
9 java -cp "bin/classes:lib/*" com.example.App
10else
11 echo "Compilation failed."
12fi