Compare commits

...

7 commits

Author SHA1 Message Date
Vadim
f05be2ff39 fixed android folders... 2024-03-14 21:47:47 +01:00
Vadim
d98b2a62ff added option to skip integration tests 2024-03-14 20:54:56 +01:00
Vadim
846a2b2254 enabled integration tests 2024-03-14 20:41:13 +01:00
Vadim
e701d65c4b fixed android keystore path 2024-03-14 20:36:28 +01:00
Vadim
5a8eee10a4 simplified release workflow tree 2024-03-14 20:36:02 +01:00
Vadim
aad833b266 fixed invalid workflow 2024-03-14 20:32:31 +01:00
Vadim
1674d7192e separated android and ios builds 2024-03-14 20:29:36 +01:00
3 changed files with 48 additions and 64 deletions

View file

@ -1,37 +0,0 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Build release
run-name: Build v${{ inputs.version }}
on:
workflow_call:
inputs:
version:
description: "Version"
required: true
type: string
binary-type:
description: "Binary type"
type: string
required: true
jobs:
build-android:
uses: ./.github/workflows/build_apk.yml
if: ${{ inputs.binary-type != 'ipa' }}
with:
binary-type: ${{ inputs.binary-type }}
flavor: prod
stage-backend: false
version: ${{ inputs.version }}
build-ios:
uses: ./.github/workflows/build_ipa.yml
if: ${{ inputs.binary-type == 'ipa' }}
with:
stage-backend: false
version: ${{ inputs.version }}

View file

@ -98,8 +98,8 @@ jobs:
- name: Restore Android keystore .jsk and .properties files
run: |
bash .github/scripts/restore_from_base64.sh "${{ secrets.KEYSTORE_PROPERTIES }}" "$RUNNER_TEMP/android/app/key.properties"
bash .github/scripts/restore_from_base64.sh "${{ secrets.KEYSTORE }}" "$RUNNER_TEMP/android/keystore.jks"
bash .github/scripts/restore_from_base64.sh "${{ secrets.KEYSTORE_PROPERTIES }}" "android/key.properties"
bash .github/scripts/restore_from_base64.sh "${{ secrets.KEYSTORE }}" "android/app/keystore.jks"
- name: Restore google-services.json
run: bash .github/scripts/restore_from_base64.sh "${{ secrets.GOOGLE_SERVICES_JSON_ANDROID }}" "android/app/google-services.json"

View file

@ -22,30 +22,48 @@ on:
description: "Release notes"
required: true
type: string
run-integration-tests:
description: "Run integration tests"
required: true
type: boolean
default: true
jobs:
run-integration-tests:
name: Run integration tests
if: false
if: ${{ inputs.run-integration-tests }}
uses: ./.github/workflows/run_integration_tests.yml
secrets: inherit
build:
name: Build ${{ matrix.binary-type != 'ipa' && 'Android' || 'iOS' }} (.${{ matrix.binary-type }})
#needs: [run-integration-tests]
build-android:
name: Build Android (.${{ matrix.binary-type }})
needs: [run-integration-tests]
if: always() && (needs.run-integration-tests.result == 'success' || needs.run-integration-tests.result == 'skipped')
strategy:
matrix:
binary-type: [apk, appbundle, ipa]
uses: ./.github/workflows/build.yml
binary-type: [apk, appbundle]
uses: ./.github/workflows/build_apk.yml
secrets: inherit
with:
binary-type: ${{ matrix.binary-type }}
flavor: prod
stage-backend: false
version: ${{ inputs.version }}
build-ios:
name: Build iOS (.ipa)
needs: [run-integration-tests]
if: always() && (needs.run-integration-tests.result == 'success' || needs.run-integration-tests.result == 'skipped')
uses: ./.github/workflows/build_ipa.yml
secrets: inherit
with:
stage-backend: false
version: ${{ inputs.version }}
generate-release-notes:
name: Generate release notes
needs: [build]
needs: [build-android, build-ios]
runs-on: ubuntu-latest
if: false
steps:
- name: Generate release notes
run: |
@ -58,16 +76,14 @@ jobs:
name: whatsnew-en-US
path: whatsnew-en-US.md
update-version-in-repo:
name: Update repo version
needs: [build]
create-github-release:
name: Create Github release
needs: [generate-release-notes]
runs-on: ubuntu-latest
if: false
permissions:
contents: write
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Increment build number & replace version number
run: bash ./.github/scripts/increment_build_number.sh ${{ github.event.inputs.version }}
@ -85,14 +101,6 @@ jobs:
branch: ${{ github.ref_name }}
unprotect_reviews: true
create-github-release:
name: Create Github release
needs: [build, generate-release-notes, update-version-in-repo]
runs-on: ubuntu-latest
if: false
permissions:
contents: write
steps:
- name: Download apk
uses: actions/download-artifact@v3
with:
@ -120,7 +128,7 @@ jobs:
create-google-play-release:
name: Create Google Play release
needs: [build, generate-release-notes]
needs: [generate-release-notes]
runs-on: ubuntu-latest
if: false
steps:
@ -188,10 +196,23 @@ jobs:
with:
name: m3_lightmeter_appbundle
create-app-store-release:
name: Create App Store release
needs: [generate-release-notes]
runs-on: macos-13
if: false
steps:
- run: echo "TODO"
cleanup:
name: Cleanup
if: ${{ always() }}
needs: [create-github-release, create-google-play-release]
needs:
[
create-github-release,
create-google-play-release,
create-app-store-release,
]
runs-on: ubuntu-latest
steps:
- name: Delete release notes artifact