Skip to content

Merge pull request #3 from infinum/fix/tag-options #7

Merge pull request #3 from infinum/fix/tag-options

Merge pull request #3 from infinum/fix/tag-options #7

Workflow file for this run

name: CI
on:
push:
branches:
- develop
- main
pull_request:
branches:
- '*'
jobs:
validation:
name: Validation
runs-on: ubuntu-latest
steps:
- name: Checkout latest code
uses: actions/[email protected]
- name: Validate Gradle Wrapper
uses: gradle/[email protected]
lint:
name: Lint
needs: [ validation ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Save Gradle Caches
uses: actions/[email protected]
with:
path: ~/.gradle/caches/
key: gradle-caches-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
gradle-caches-${{ runner.os }}-
- name: Lint
run: ./gradlew lintAll
- name: Stop Gradle
run: ./gradlew --stop
detekt:
name: Detekt
needs: [ validation ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Save Gradle Caches
uses: actions/[email protected]
with:
path: ~/.gradle/caches/
key: gradle-caches-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
gradle-caches-${{ runner.os }}-
- name: Detekt
run: ./gradlew detektAll
- name: Stop Gradle
run: ./gradlew --stop
ktlint:
name: ktlint
needs: [ validation ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Save Gradle Caches
uses: actions/[email protected]
with:
path: ~/.gradle/caches/
key: gradle-caches-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
gradle-caches-${{ runner.os }}-
- name: ktlint
run: ./gradlew ktlintAll
- name: Stop Gradle
run: ./gradlew --stop
cpd:
name: CPD
needs: [ validation ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Save Gradle Caches
uses: actions/[email protected]
with:
path: ~/.gradle/caches/
key: gradle-caches-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
gradle-caches-${{ runner.os }}-
- name: CPD
run: ./gradlew cpdAll
- name: Stop Gradle
run: ./gradlew --stop
tests:
name: Tests
needs: [ validation, lint, detekt, ktlint, cpd ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Save Gradle Caches
uses: actions/[email protected]
with:
path: ~/.gradle/caches/
key: gradle-caches-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
gradle-caches-${{ runner.os }}-
- name: Unit tests
run: ./gradlew clean testDebugUnitTest
- name: Stop Gradle
run: ./gradlew --stop