[TEST] Try to cause the error of ktlint and detekt #88
This file contains 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: Danger Checks | |
on: | |
pull_request: | |
branches: | |
- '*' | |
jobs: | |
pr: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 100 | |
- name: Set up Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.3' | |
- name: Danger Checks | |
env: | |
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gem install bundler | |
bundle config set --local gemfile danger/gemfiles/GemPR | |
bundle install | |
bundle exec danger --dangerfile=danger/dangerfiles/DangerPR --danger_id=pr | |
ktlint: | |
runs-on: ubuntu-latest | |
needs: [pr] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 100 | |
- name: Check ktlint | |
run: ./gradlew ktlintCheck | |
- name: Set up Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.3' | |
- name: Danger Checks | |
env: | |
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gem install bundler | |
bundle config set --local gemfile danger/gemfiles/GemKtlint | |
bundle install | |
bundle exec danger --dangerfile=danger/dangerfiles/DangerKtlint --danger_id=ktlint | |
- name: Archive ktlint Reports | |
uses: actions/upload-artifact@v2 | |
with: | |
name: ktlint-report | |
path: | | |
app/build/reports/ktlint/* | |
detekt: | |
runs-on: ubuntu-latest | |
needs: [pr] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 100 | |
- name: Check detekt | |
run: ./gradlew detekt | |
- name: Set up Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.3' | |
- name: Danger Checks | |
env: | |
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gem install bundler | |
bundle config set --local gemfile danger/gemfiles/GemDeteKt | |
bundle install | |
bundle exec danger --dangerfile=danger/dangerfiles/DangerDeteKt --danger_id=detekt | |
- name: Archive detekt Reports | |
uses: actions/upload-artifact@v2 | |
with: | |
name: detekt-report | |
path: | | |
app/build/reports/detekt/detekt.html | |
androidLint: | |
runs-on: ubuntu-latest | |
needs: [pr] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 100 | |
- name: Check Android lint | |
run: ./gradlew lint | |
- name: Set up Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.3' | |
- name: Danger Checks | |
env: | |
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gem install bundler | |
bundle config set --local gemfile danger/gemfiles/GemAndroidLint | |
bundle install | |
bundle exec danger --dangerfile=danger/dangerfiles/DangerAndroidLint --danger_id=androidlint | |
- name: Archive android lint Reports | |
uses: actions/upload-artifact@v2 | |
with: | |
name: android-lint-report | |
path: | | |
app/build/reports/lint-results-debug.html |