From b5923a712dedb0bb311c0893406a7518f73eeaad Mon Sep 17 00:00:00 2001 From: Joscha <34318751+josxha@users.noreply.github.com> Date: Mon, 29 Apr 2024 18:29:33 +0200 Subject: [PATCH] Create update-ios-pods.yml --- .github/workflows/update-ios-pods.yml | 36 +++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/update-ios-pods.yml diff --git a/.github/workflows/update-ios-pods.yml b/.github/workflows/update-ios-pods.yml new file mode 100644 index 0000000..eff4579 --- /dev/null +++ b/.github/workflows/update-ios-pods.yml @@ -0,0 +1,36 @@ +name: Update iOS CocoaPods +on: + workflow_dispatch: +jobs: + update-pods: + runs-on: macos-latest + name: pod update + steps: + - name: Checkout project + uses: actions/checkout@v4 + - name: Setup Flutter + uses: subosito/flutter-action@v2 + with: + flutter-version: '3.x' + - name: Get Flutter dependencies + working-directory: wakelock_plus/ios + run: flutter pub get + - name: Update CocoaPods + working-directory: wakelock_plus/example/ios + run: | + pod repo update && \ + pod update + - name: Check difference + run: | + git add --all . && \ + status=$(git status -s .) && \ + echo $status && \ + echo "GIT_STATUS=${status//$'\n'/\\n}" >> $GITHUB_ENV + - name: Push changes + if: "contains(env.GIT_STATUS, 'ios')" + run: | + git add --all . && \ + git config --global user.email "action@github.com" && \ + git config --global user.name "Github CI" && \ + git commit -a -m "pod update" && \ + git push \ No newline at end of file