Merge pull request #2067 from microsoft/dependabot/github_actions/act… #3601
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: "Checks the SDK only using APIs from the targeted API level" | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| lint-api-level: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-java@v5 | |
| with: | |
| distribution: 'temurin' | |
| java-version: 21 | |
| cache: gradle | |
| - name: Setup Android SDK | |
| uses: android-actions/setup-android@v3.2.2 | |
| - name: Build SDK with Android project configuration | |
| id: lint | |
| run: ./gradlew --no-daemon build -Pandroid=true | |
| - name: Upload linting results | |
| if: failure() && steps.lint.outcome == 'failure' | |
| uses: actions/upload-artifact@v5 | |
| with: | |
| name: lint-report | |
| path: ./**/build/reports |