From d2a1aa620ddd8187225611e32d50eca0ba683ab3 Mon Sep 17 00:00:00 2001 From: Giorgio Azzinnaro Date: Sat, 21 Dec 2024 18:36:33 +0100 Subject: [PATCH] ci: ios scripts --- ios/ci_scripts/ci_post_clone.sh | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100755 ios/ci_scripts/ci_post_clone.sh diff --git a/ios/ci_scripts/ci_post_clone.sh b/ios/ci_scripts/ci_post_clone.sh new file mode 100755 index 0000000..e6315d8 --- /dev/null +++ b/ios/ci_scripts/ci_post_clone.sh @@ -0,0 +1,29 @@ +#!/bin/sh + +# CI/CD for Flutter +# From https://docs.flutter.dev/deployment/cd#post-clone-script + +# Fail this script if any subcommand fails. +set -e + +# The default execution directory of this script is the ci_scripts directory. +cd $CI_PRIMARY_REPOSITORY_PATH # change working directory to the root of your cloned repo. + +# Install Flutter using git. +git clone https://github.com/flutter/flutter.git --depth 1 -b stable $HOME/flutter +export PATH="$PATH:$HOME/flutter/bin" + +# Install Flutter artifacts for iOS (--ios), or macOS (--macos) platforms. +flutter precache --ios + +# Install Flutter dependencies. +flutter pub get + +# Install CocoaPods using Homebrew. +HOMEBREW_NO_AUTO_UPDATE=1 # disable homebrew's automatic updates. +brew install cocoapods + +# Install CocoaPods dependencies. +cd ios && pod install # run `pod install` in the `ios` directory. + +exit 0