fix(f&f): disable mapping file upload if credentials are not availabl… #16
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: Android CI | |
# Triggers the workflow on push to the main branch or on pull requests | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
# Step 1: Checkout the repository code | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
# Step 2: Set up JDK 17 (required for Gradle) | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: '17' | |
# Step 3: Cache Gradle dependencies | |
- name: Cache Gradle dependencies | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | |
restore-keys: | | |
${{ runner.os }}-gradle- | |
# Step 4: Build the project using Gradle | |
- name: Build with Gradle | |
run: ./gradlew build | |
env: | |
SAMPLE_PROJECT_ID: ${{ secrets.SAMPLE_PROJECT_ID }} | |
SAMPLE_MAPPING_UPLOAD_CLIENT_ID: ${{ secrets.SAMPLE_MAPPING_UPLOAD_CLIENT_ID }} | |
SAMPLE_MAPPING_UPLOAD_CLIENT_SECRET: ${{ secrets.SAMPLE_MAPPING_UPLOAD_CLIENT_SECRET }} |