diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..5520b77 --- /dev/null +++ b/build.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# Direct build script for Maven project + +echo "Current directory: $(pwd)" +echo "Building project with Maven..." + +# Run Maven build using the exact pom.xml location +mvn clean package -f "$(pwd)/pom.xml" + +echo "Build complete. JAR file should be in target/ directory." diff --git a/debug_build.sh b/debug_build.sh new file mode 100755 index 0000000..655ce62 --- /dev/null +++ b/debug_build.sh @@ -0,0 +1,46 @@ +#!/bin/bash +# Debug script for build issues + +echo "=== Environment Information ===" +echo "Current directory: $(pwd)" +echo "Java version:" +java -version +echo "" +echo "Maven version:" +mvn --version +echo "" + +echo "=== Project structure ===" +find . -type f -name "*.kt" | sort +find . -type f -name "pom.xml" +echo "" + + +echo "=== Debugging build for MOTD ===" +echo "Changing to directory: " +cd +echo "Current directory: $(pwd)" + +echo "Checking for POM file:" +ls -la pom.xml + +echo "Checking Kotlin source files:" +find . -type f -name "*.kt" | sort + +echo "Compiling Kotlin sources:" +mvn compile + +echo "Checking for MOTDGuiHandler class:" +find . -type f -name "MOTDGuiHandler.kt" +grep -r "MOTDGuiHandler" --include="*.kt" . +echo "" + +echo "Checking package structure:" +find ./src -type d | sort +echo "" + +echo "Checking import statements in MOTDCommand.kt:" +grep -r "import" --include="MOTDCommand.kt" . +echo "" + +cd ..