Prepare release 0.5.0 #98
Workflow file for this run
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: Deploy to Play Store | |
on: | |
workflow_dispatch: | |
# Enable manual run | |
inputs: | |
lane: | |
description: "Fastlane lane to use (internal OR beta OR promote_to_production OR production)" | |
required: true | |
default: "beta" | |
push: | |
tags: | |
- "v*" | |
- "beta-v*" | |
jobs: | |
fastlane-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'zulu' | |
java-version: '17' | |
# Set up Flutter. | |
- name: Clone Flutter repository with stable channel | |
uses: subosito/flutter-action@v2 | |
with: | |
channel: stable | |
- run: flutter config --no-analytics | |
# Checkout code and get packages. | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- run: flutter packages get | |
working-directory: kitchenowl | |
# Decide track internal|beta|production (not in use yet) | |
- name: Decide track | |
id: track | |
run: | | |
if [[ $REF == "refs/tags/v"* ]] | |
then | |
echo "track=production" >> $GITHUB_ENV | |
elif [[ $REF == "refs/tags/beta-v"* ]] | |
then | |
echo "track=beta" >> $GITHUB_ENV | |
else | |
echo "track=internal" >> $GITHUB_ENV | |
fi | |
env: | |
REF: ${{ github.ref }} | |
# Setup Ruby, Bundler, and Gemfile dependencies | |
- name: Setup Fastlane | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: "3.2" | |
bundler-cache: true | |
working-directory: kitchenowl/android | |
- name: Configure Keystore | |
run: | | |
echo "$PLAY_STORE_UPLOAD_KEY" | base64 --decode > app/upload-keystore.jks | |
echo "storeFile=upload-keystore.jks" >> key.properties | |
echo "keyAlias=$KEYSTORE_KEY_ALIAS" >> key.properties | |
echo "storePassword=$KEYSTORE_STORE_PASSWORD" >> key.properties | |
echo "keyPassword=$KEYSTORE_KEY_PASSWORD" >> key.properties | |
env: | |
PLAY_STORE_UPLOAD_KEY: ${{ secrets.PLAY_STORE_UPLOAD_KEY }} | |
KEYSTORE_KEY_ALIAS: ${{ secrets.KEYSTORE_KEY_ALIAS }} | |
KEYSTORE_KEY_PASSWORD: ${{ secrets.KEYSTORE_KEY_PASSWORD }} | |
KEYSTORE_STORE_PASSWORD: ${{ secrets.KEYSTORE_STORE_PASSWORD }} | |
working-directory: kitchenowl/android | |
# Build and deploy with Fastlane (by default, to internal track) 🚀. | |
# Naturally, promote_to_production only deploys. | |
- run: bundle exec fastlane ${{ github.event.inputs.lane || 'internal' }} | |
env: | |
PLAY_STORE_CONFIG_JSON: ${{ secrets.PLAY_STORE_CONFIG_JSON }} | |
working-directory: kitchenowl/android |