forked from eatvio/eatvio_app
Merge pull request 'sync main' (#2) from eatvio/eatvio_app:main into main
Reviewed-on: apoloz/eatvio_app#2
This commit is contained in:
@@ -3,7 +3,7 @@ name: Eatvio App Android Test
|
||||
on: [ pull_request ]
|
||||
|
||||
env:
|
||||
flutter_version: "3.29.1"
|
||||
flutter_version: "3.32.0"
|
||||
java_version: "21.x"
|
||||
flutter_channel: "stable"
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ name: Eatvio App Android Test on custom docker
|
||||
on: [ pull_request ]
|
||||
|
||||
env:
|
||||
flutter_version: "3.29.1"
|
||||
flutter_version: "3.32.0"
|
||||
java_version: "21.x"
|
||||
flutter_channel: "stable"
|
||||
my_local_cache_dir: "/opt/hostedtoolcache/"
|
||||
|
||||
36
.gitea/workflows/test-flight-cd.yaml
Normal file
36
.gitea/workflows/test-flight-cd.yaml
Normal file
@@ -0,0 +1,36 @@
|
||||
name: "Build Test Flight"
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- test-flight
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: [macos-arm64]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
|
||||
- name: Unlock login keychain
|
||||
run: |
|
||||
security unlock-keychain -p "$KEYCHAIN_PASSWORD" /Users/gitea_runner_ci/Library/Keychains/login.keychain-db
|
||||
env:
|
||||
KEYCHAIN_PASSWORD: ${{ vars.IOS_RUNNER_CI_PASSWORD }}
|
||||
|
||||
- name: Flutter build
|
||||
run: |
|
||||
flutter clean
|
||||
flutter pub get
|
||||
flutter pub upgrade
|
||||
flutter pub run build_runner build --delete-conflicting-outputs
|
||||
cd ios
|
||||
pod update
|
||||
fastlane beta
|
||||
env:
|
||||
LANG: en_US.UTF-8
|
||||
LC_ALL: en_US.UTF-8
|
||||
MATCH_PASSWORD: ${{ vars.IOS_RUNNER_CI_PASSWORD }}
|
||||
MATCH_GIT_URL: http://gitea.office.local:3000/mso7nueh/fastlane
|
||||
FASTLANE_USER: eatvio2023@icloud.com
|
||||
FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD: ${{ vars.FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD }}
|
||||
@@ -3,7 +3,7 @@ name: Eatvio App Android Test
|
||||
on: [ pull_request ]
|
||||
|
||||
env:
|
||||
flutter_version: "3.29.1"
|
||||
flutter_version: "3.32.0"
|
||||
java_version: "21.x"
|
||||
flutter_channel: "stable"
|
||||
my_local_cache_dir: "/opt/hostedtoolcache/"
|
||||
@@ -16,6 +16,20 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Create key.properties file
|
||||
run: |
|
||||
cat > android/key.properties <<EOF
|
||||
storePassword=${{ vars.SIGNING_STORE_PASSWORD }}
|
||||
keyPassword=${{ vars.SIGNING_KEY_PASSWORD }}
|
||||
keyAlias=${{ vars.SIGNING_KEY_ALIAS }}
|
||||
storeFile=upload-keystore.jks
|
||||
EOF
|
||||
|
||||
- name: Decode keystore from secret
|
||||
run: |
|
||||
echo "${{ vars.SIGNING_KEY_JKS }}"
|
||||
printf "%s" "${{ vars.SIGNING_KEY_JKS }}" | base64 -d > android/app/upload-keystore.jks
|
||||
|
||||
- name: Cache Android SDK
|
||||
id: cache-sdk
|
||||
uses: "https://gitea.com/actions/cache@v4"
|
||||
@@ -41,6 +55,8 @@ jobs:
|
||||
wget https://dl.google.com/android/repository/commandlinetools-linux-7583922_latest.zip -O commandlinetools.zip
|
||||
unzip commandlinetools.zip
|
||||
mkdir -p ${{ env.my_local_cache_dir }}Android/Sdk/cmdline-tools/latest
|
||||
rm -rf ${{ env.my_local_cache_dir }}Android/Sdk/cmdline-tools/latest
|
||||
mkdir -p ${{ env.my_local_cache_dir }}Android/Sdk/cmdline-tools/latest
|
||||
mv cmdline-tools/* ${{ env.my_local_cache_dir }}Android/Sdk/cmdline-tools/latest/
|
||||
export ANDROID_SDK_ROOT=${{ env.my_local_cache_dir }}Android/Sdk
|
||||
export PATH=$PATH:${{ env.my_local_cache_dir }}Android/Sdk/cmdline-tools/latest/bin
|
||||
@@ -91,7 +107,10 @@ jobs:
|
||||
flutter doctor -v
|
||||
|
||||
- name: Get dependencies
|
||||
run: flutter pub get
|
||||
run: |
|
||||
flutter clean
|
||||
flutter pub get
|
||||
dart run build_runner build --delete-conflicting-outputs
|
||||
|
||||
- name: Native Analyze
|
||||
run: flutter analyze
|
||||
@@ -100,13 +119,13 @@ jobs:
|
||||
run: flutter test
|
||||
|
||||
- name: Build apk
|
||||
run: flutter build apk --profile
|
||||
run: flutter build apk --release
|
||||
|
||||
- name: Rename and move apk
|
||||
run: |
|
||||
TIMESTAMP=$(TZ=Europe/Moscow date +'%Y-%m-%d-%H-%M')
|
||||
APK_NAME="eatvio_app_${TIMESTAMP}.apk"
|
||||
mv build/app/outputs/flutter-apk/app-profile.apk $APK_NAME
|
||||
mv build/app/outputs/flutter-apk/app-release.apk $APK_NAME
|
||||
echo "APK build finished $APK_NAME"
|
||||
echo "APK_NAME=$APK_NAME" >> $GITHUB_ENV
|
||||
|
||||
|
||||
Reference in New Issue
Block a user