-
Notifications
You must be signed in to change notification settings - Fork 536
31 lines (30 loc) · 981 Bytes
/
lint-pr.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: Comments Android lint warnings on pull request
on: pull_request
jobs:
lint:
name: Comments lint result on PR
runs-on: macos-latest
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: set up JDK
uses: actions/setup-java@v3
with:
distribution: oracle
java-version: 17
cache: gradle
- name: Run detekt
run: ./gradlew :app:detekt
continue-on-error: true
- name: Run Android Lint
run: ./gradlew :app:lintAnalyticsDebug
- name: Run Android Lint Reporter to report Lint and Detekt result to PR
env:
PR_NUMBER: ${{ github.event.number }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
./gradlew report --no-configuration-cache -PgithubPullRequestId=$PR_NUMBER -PgithubToken=$GITHUB_TOKEN