Skip to content

Commit

Permalink
Update workflows to update pods on dev and install pods on master and…
Browse files Browse the repository at this point in the history
… release
  • Loading branch information
XavierPaquet-Rapold committed Oct 27, 2023
1 parent 23daf6e commit 3dbf855
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 6 deletions.
23 changes: 21 additions & 2 deletions .github/workflows/dev-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ on:
- 'README.fr.md'
- 'android/fastlane/**'
- 'ios/fastlane/**'
- '.github/master-workflow.yaml'
- '.github/release-workflow.yaml'
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
Expand Down Expand Up @@ -241,9 +243,26 @@ jobs:
run: |
flutter pub get
cd ios
rm Podfile.lock
pod install --repo-update
pod update
flutter clean
- name: Commit pod updates
if: matrix.target == 'iOS'
id: commit_pod_versions
uses: stefanzweifel/git-auto-commit-action@v4
with:
file_pattern: "*.lock"
commit_user_name: github-actions[bot]
commit_user_email: 41898282+github-actions[bot]@users.noreply.github.com
commit_message: "[BOT] Applying pod update."
add_options: '-u'

# Fail workflow, because new commit will execute workflow
- if: ${{ matrix.target == 'iOS' && steps.commit_pod_versions.outputs.changes_detected == 'true' }}
name: Fail workflow if pod version change
run: |
echo 'Pod update applied, running bot commit workflow'
exit 1
# Get dependencies and decrypt needed files.
- run: flutter pub get
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/master-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ on:
- 'README.fr.md'
- 'android/fastlane/**'
- 'ios/fastlane/**'
- '.github/dev-workflow.yaml'
- '.github/release-workflow.yaml'

concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
Expand Down Expand Up @@ -175,8 +178,7 @@ jobs:
run: |
flutter pub get
cd ios
rm Podfile.lock
pod install --repo-update
pod install
flutter clean
# Get dependencies and decrypt needed files.
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/release-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,7 @@ jobs:
run: |
flutter pub get
cd ios
rm Podfile.lock
pod install --repo-update
pod install
flutter clean
- run: flutter doctor -v

Expand Down

0 comments on commit 3dbf855

Please sign in to comment.