[REFACTOR/YAF-000] κ³΅ν΅ μ»΄ν¬λνΈ μμ λ° μΆκ°λ₯Ό μνν©λλ€. #17
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: Orbit CI | |
on: | |
pull_request: | |
branches: [develop] | |
paths: | |
- 'app/**' | |
- 'build.gradle' | |
- '**/*.kt' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
# Gradle Cache | |
- name: Cache Gradle packages | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('gradle.properties', '**/*.gradle*', '**/gradle-wrapper.properties') }} | |
restore-keys: | | |
${{ runner.os }}-gradle- | |
# Checkout Code | |
- name: Checkout the code | |
uses: actions/checkout@v4 | |
# Setup JDK | |
- name: Setup JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'corretto' | |
java-version: '17' | |
# Setup Android SDK | |
- name: Setup Android SDK | |
uses: android-actions/setup-android@v3 | |
# Grant Execute Permission | |
- name: Grant execute permission for gradlew | |
run: chmod +x gradlew | |
# Decode google-services.json | |
- name: Decode google-services.json | |
env: | |
FIREBASE_SECRET: ${{ secrets.FIREBASE_SECRET }} | |
run: echo $FIREBASE_SECRET > app/google-services.json | |
# Add Local Properties | |
- name: Add Local Properties | |
env: | |
BASE_URL: ${{ secrets.BASE_URL }} | |
run: echo "baseUrl=$BASE_URL" >> local.properties | |
# Run Lint and Build | |
- name: Run lint and build | |
run: ./gradlew ktlintCheck assembleDebug |