Merge pull request #352 from onuralpszr/renovate/android.gradle.plugin #739
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: 🚀 Android CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| - dev | |
| branch_protection_rule: | |
| types: [created] | |
| # Allows you to run this workflow manually from the Actions tab | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 📥 Checkout Source Code | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v4.2.3 | |
| with: | |
| path: | | |
| ~/.gradle/caches | |
| ~/.gradle/wrapper | |
| key: ${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }}-${{ hashFiles('**/buildSrc/**/*.kt') }} | |
| - name: 🛠️ Setup Android-OpenCV-SDK | |
| run: ./setupOpenCV_4x.sh | |
| - name: ☕ Set up JDK 21 | |
| uses: actions/setup-java@dd06d9cba3e5552c54d9f8ea23572deb30010f7c # v6.0.0 | |
| with: | |
| distribution: temurin | |
| java-version: 21.X | |
| - name: 🎨 Check Code Style | |
| run: ./gradlew spotlessCheck | |
| - name: ⚡ Build & Verify (Debug) | |
| run: ./gradlew spotlessCheck assembleDebug :app:lintDebug :app:testDebugUnitTest | |
| - name: 📤 Upload Debug APK | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: debug apk | |
| path: app/build/outputs/apk/debug/app-debug.apk |