Skip to content

MOEN-31868: Ktlint and CI Setup #2

MOEN-31868: Ktlint and CI Setup

MOEN-31868: Ktlint and CI Setup #2

name: Verify Pull Request
on:
workflow_dispatch:
pull_request:
types: [ opened, reopened, ready_for_review, synchronize ]
branches: [ "development", "master" ]
jobs:
assemble-verification:
runs-on: ubuntu-latest
if: ${{ !github.event.pull_request.draft }}
strategy:
fail-fast: true
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up repository
run: |
echo segmentWriteKey="Dummy Segment Key" >> ./local.properties
echo moengageAppId="Dummy MoEngage Key" >> ./local.properties
- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 17
- name: Set up gradle cache
uses: gradle/gradle-build-action@v2
- name: Build project
run: ./gradlew assemble
- name: Ktlint check
run: ./gradlew ktlintcheck