forked from orevial/uni_links
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
129 lines (128 loc) · 5.08 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
matrix:
include:
# Job 1) Run analyzer
- os: linux
env:
- SHARD=Analyze
sudo: false
addons:
apt:
# Flutter depends on /usr/lib/x86_64-linux-gnu/libstdc++.so.6 version GLIBCXX_3.4.18
sources:
- ubuntu-toolchain-r-test # if we don't specify this, the libstdc++6 we get is the wrong version
packages:
- libstdc++6
- fonts-droid-fallback
before_script:
- git clone https://github.com/flutter/flutter.git /tmp/flutter
- export PATH=/tmp/flutter/bin:/tmp/flutter/bin/cache/dart-sdk/bin:$PATH
- flutter doctor
- pub global activate tuneup
- flutter packages get
script:
- pub global run tuneup check
# Job 2) Check format and run tests
- os: linux
env:
- SHARD=Format+Test
jdk: oraclejdk11
sudo: false
addons:
apt:
# Flutter depends on /usr/lib/x86_64-linux-gnu/libstdc++.so.6 version GLIBCXX_3.4.18
sources:
- ubuntu-toolchain-r-test # if we don't specify this, the libstdc++6 we get is the wrong version
- llvm-toolchain-precise # for clang-format-5.0
packages:
- libstdc++6
- fonts-droid-fallback
- clang-format-5.0
before_script:
- wget https://github.com/google/google-java-format/releases/download/google-java-format-1.8/google-java-format-1.8-all-deps.jar
- git clone https://github.com/flutter/flutter.git /tmp/flutter
- export PATH=/tmp/flutter/bin:/tmp/flutter/bin/cache/dart-sdk/bin:$PATH
- flutter doctor
script:
## uni_links_platform_interface
- cd uni_links_platform_interface
# Part 1) format
- shopt -s globstar
- flutter format ./**/*.dart
- java -jar google-java-format-1.8-all-deps.jar -a --replace ./**/*.java
- clang-format-5.0 -i --style=Google ./**/*.h ./**/*.m
# Part 2) test
- flutter test --color
- cd ..
## uni_links
- cd uni_links
# Part 1) format
- shopt -s globstar
- flutter format ./**/*.dart
- java -jar google-java-format-1.8-all-deps.jar -a --replace ./**/*.java
- clang-format-5.0 -i --style=Google ./**/*.h ./**/*.m
# Part 2) test
- flutter test --color
- cd ..
# Job 3) Build example APKs and run Java tests
# - os: linux
# env:
# - SHARD=Build-example-APK+Java-Tests
# jdk: oraclejdk8
# sudo: false
# addons:
# apt:
# # Flutter depends on /usr/lib/x86_64-linux-gnu/libstdc++.so.6 version GLIBCXX_3.4.18
# sources:
# - ubuntu-toolchain-r-test # if we don't specify this, the libstdc++6 we get is the wrong version
# packages:
# - lib32stdc++6 # https://github.com/flutter/flutter/issues/6207
# - libstdc++6
# - fonts-droid
# before_script:
# - wget https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip
# - mkdir android-sdk
# - unzip -qq sdk-tools-linux-3859397.zip -d android-sdk
# - export ANDROID_HOME=`pwd`/android-sdk
# - export PATH=`pwd`/android-sdk/tools/bin:$PATH
# - mkdir -p /home/travis/.android # silence sdkmanager warning
# - echo 'count=0' > /home/travis/.android/repositories.cfg # silence sdkmanager warning
# # suppressing output of sdkmanager to keep log under 4MB (travis limit)
# - echo y | sdkmanager "tools" >/dev/null
# - echo y | sdkmanager "platform-tools" >/dev/null
# - echo y | sdkmanager "build-tools;26.0.3" >/dev/null
# - echo y | sdkmanager "platforms;android-26" >/dev/null
# - echo y | sdkmanager "extras;android;m2repository" >/dev/null
# - echo y | sdkmanager "extras;google;m2repository" >/dev/null
# - echo y | sdkmanager "patcher;v4" >/dev/null
# - sdkmanager --list
# - wget http://services.gradle.org/distributions/gradle-4.1-bin.zip
# - unzip -qq gradle-4.1-bin.zip
# - export GRADLE_HOME=$PWD/gradle-4.1
# - export PATH=$GRADLE_HOME/bin:$PATH
# - gradle -v
# - git clone https://github.com/flutter/flutter.git /tmp/flutter
# - export PATH=/tmp/flutter/bin:/tmp/flutter/bin/cache/dart-sdk/bin:$PATH
# - flutter doctor
# script:
# - pushd example; flutter build apk; popd
# # Job 4) Build example IPAs
# - os: osx
# env:
# - SHARD=Build-example-IPA
# language: generic
# osx_image: xcode9.3
# before_script:
# - brew update
# - brew install libimobiledevice
# - brew install ideviceinstaller
# - brew install ios-deploy
# - pod repo update
# - gem update cocoapods
# - git clone https://github.com/flutter/flutter.git /tmp/flutter
# - export PATH=/tmp/flutter/bin:/tmp/flutter/bin/cache/dart-sdk/bin:$PATH
# - flutter doctor
# script:
# - pushd example; flutter build ios --no-codesign; popd
cache:
directories:
- $HOME/.pub-cache