forked from FabrizioBrancati/BFKit-Swift
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
50 lines (46 loc) · 1.54 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
os:
- linux
- osx
language: generic
sudo: required
dist: trusty
osx_image: xcode8.2
before_install:
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
gem install xcpretty -N --no-ri --no-rdoc;
gem install cocoapods --pre --no-rdoc --no-ri --no-document;
brew update;
brew outdated carthage || brew upgrade carthage;
fi
install:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
eval "$(curl -sL https://gist.githubusercontent.com/kylef/5c0475ff02b7c7671d2a/raw/02090c7ede5a637b76e6df1710e83cd0bbe7dcdf/swiftenv-install.sh)";
fi
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
./install_swiftlint.sh;
fi
script:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
swiftenv version;
fi
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
swift -version
xcodebuild -version;
xcodebuild -showsdks;
swiftlint;
sleep 5;
set -o pipefail;
xcodebuild clean test -project BFKit.xcodeproj -scheme BFKit -destination "platform=iOS Simulator,OS=10.1,name=iPhone 7 Plus" -enableCodeCoverage YES | xcpretty;
xcodebuild -project Example/BFKitExample.xcodeproj -scheme BFKitExample -destination "platform=iOS Simulator,OS=10.1,name=iPhone 7 Plus" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty;
pod lib lint --verbose;
carthage build --no-skip-current;
fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
swift build;
swift test;
fi
after_success:
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
bash <(curl -s https://codecov.io/bash);
sleep 5;
fi