name: build on: push: branches: [main] pull_request: branches: [main] jobs: assemble-debug: name: Assemble debug APK runs-on: ubuntu-latest steps: # Checkout: clone the repo directly instead of actions/checkout - name: Checkout run: | git clone https://git.trevena.info/nick/incido.git repo cd repo # Shallow clone for speed but fetch full history needed by Gradle git fetch --unshallow origin main # Set up JDK 17 via apt instead of actions/setup-java - name: Set up JDK 17 run: | apt-get update -qq apt-get install -y -qq openjdk-17-jdk > /dev/null 2>&1 echo "JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))" >> $GITHUB_ENV - name: Grant execute permission for gradlew run: chmod +x repo/gradlew - name: Cache Gradle packages run: | mkdir -p ~/.gradle/caches ~/.gradle/wrapper # Copy cached gradle wrapper if available if [ -d .github/workflows/gradle-cache ]; then cp -r .github/workflows/gradle-cache/* ~/.gradle/ 2>/dev/null || true fi - name: Build debug APK run: cd repo && ./gradlew assembleDebug # Note: artifact upload requires Docker or Gitea's native actions # Skipping artifact upload — download APK from runner workspace if needed