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 Fastlane with Firebase App Distribution Workflow | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
distribute_to_firebase: | |
runs-on: windows-latest # Adjust to your preferred OS environment | |
steps: | |
- name: Checkout my repo code | |
uses: actions/checkout@v2 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: '11' | |
distribution: 'temurin' | |
- name: Install Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
channel: stable | |
- name: Setup Ruby and Bundler | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: "3.2.3" | |
bundler-cache: true | |
working-directory: C:/Users/owner/doctor/android/Doctor_app # Ensure this path is correct | |
env: | |
JAVA_HOME: C:\hostedtoolcache\windows\Java_Temurin-Hotspot_jdk\11.0.23-9\x64 | |
FLUTTER_ROOT: C:\hostedtoolcache\windows\flutter\stable-3.22.2-x64 | |
PUB_CACHE: C:\Users\runneradmin\AppData\Local\Pub\Cache | |
GEM_HOME: D:\a\_temp/bundle | |
BUNDLE_PATH: vendor/bundle | |
BUNDLE_JOBS: 4 | |
BUNDLE_RETRY: 3 | |
- name: Debug Current Directory | |
run: | | |
dir C:/Users/owner/doctor/android/Doctor_app # List files in Doctor_app directory for debugging | |
- name: Add x86_64-linux platform to Gemfile.lock | |
run: | | |
bundle lock --add-platform x86_64-linux | |
- name: Install dependencies | |
run: | | |
bundle install | |
- name: Build and Distribute App | |
env: | |
FIREBASE_CLI_TOKEN: ${{ secrets.FIREBASE_CLI_TOKEN }} | |
run: | | |
bundle exec fastlane android firebase_distribution | |
working-directory: C:/Users/owner/doctor/android/Doctor_app |