Skip to content

Commit

Permalink
Configured macOS builds on Cirrus CI (firebase#635)
Browse files Browse the repository at this point in the history
plus use sharding for `flutter_plugin_tools`
  • Loading branch information
fkorotkov authored and Hixie committed Jun 26, 2018
1 parent 7ba8f6f commit 0aee5a1
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 22 deletions.
32 changes: 29 additions & 3 deletions .cirrus.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
container:
image: cirrusci/flutter:latest

task:
container:
image: cirrusci/flutter:latest
upgrade_script:
- flutter channel master
- flutter upgrade
Expand All @@ -18,6 +17,33 @@ task:
- name: analyze
script: ./script/incremental_build.sh analyze
- name: build-apks+java-test
env:
matrix:
PLUGIN_SHARDING: "--shardIndex 0 --shardCount 2"
PLUGIN_SHARDING: "--shardIndex 1 --shardCount 2"
script:
- ./script/incremental_build.sh build-examples --apk
- ./script/incremental_build.sh java-test # must come after apk build

task:
name: build-ipas
osx_instance:
image: high-sierra-xcode-9.4
env:
PATH: $PATH:/usr/local/bin
matrix:
PLUGIN_SHARDING: "--shardIndex 0 --shardCount 2"
PLUGIN_SHARDING: "--shardIndex 1 --shardCount 2"
setup_script:
- brew update
- brew install libimobiledevice
- brew install ideviceinstaller
- brew install ios-deploy
- pod repo update
- git clone https://github.com/flutter/flutter.git
- export PATH=`pwd`/flutter/bin:`pwd`/flutter/bin/cache/dart-sdk/bin:$PATH
- flutter doctor
- pub global activate flutter_plugin_tools
build_script:
- export PATH=`pwd`/flutter/bin:`pwd`/flutter/bin/cache/dart-sdk/bin:$PATH
- ./script/incremental_build.sh build-examples --ipa
4 changes: 2 additions & 2 deletions script/incremental_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD)

if [ "${BRANCH_NAME}" = "master" ]; then
echo "Running for all packages"
pub global run flutter_plugin_tools "$@"
pub global run flutter_plugin_tools "$@" $PLUGIN_SHARDING
else
# Make sure there is up-to-date master.
git fetch origin master
Expand All @@ -27,7 +27,7 @@ else

if [ "${FLUTTER_CHANGED_PACKAGES}" = "" ] || [ $FLUTTER_CHANGED_GLOBAL -gt 0 ]; then
echo "Running for all packages"
pub global run flutter_plugin_tools "$@"
pub global run flutter_plugin_tools "$@" $PLUGIN_SHARDING
else
echo "Running only for $FLUTTER_CHANGED_PACKAGES"
pub global run flutter_plugin_tools "$@" --plugins=$FLUTTER_CHANGED_PACKAGES
Expand Down
17 changes: 0 additions & 17 deletions script/plugin_tools.sh

This file was deleted.

0 comments on commit 0aee5a1

Please sign in to comment.