on master help sign in
Add Travis and podspec
94f45efLouis D'hauwe
.travis.ymlnew file+49
@@ -0,0 +1,49 @@
1+language: objective-c
2+osx_image: xcode9.1
3+branches:
4+ only:
5+ - master
6+env:
7+ global:
8+ - LC_CTYPE=en_US.UTF-8
9+ - LANG=en_US.UTF-8
10+ - WORKSPACE=HueKit.xcworkspace
11+ - IOS_FRAMEWORK_SCHEME="HueKit"
12+ - EXAMPLE_SCHEME="Example"
13+ matrix:
14+
15+ - DESTINATION="OS=10.0,name=iPhone 7" SCHEME="$IOS_FRAMEWORK_SCHEME" RUN_TESTS="NO" BUILD_EXAMPLE="YES" CODE_COV="NO"
16+ - DESTINATION="OS=11.1,name=iPad Pro (9.7-inch)" SCHEME="$IOS_FRAMEWORK_SCHEME" RUN_TESTS="NO" BUILD_EXAMPLE="YES" CODE_COV="NO"
17+
18+script:
19+ - set -o pipefail
20+ - xcodebuild -version
21+ - xcodebuild -showsdks
22+
23+ # Build Framework in Debug and Run Tests if specified
24+ - if [ $RUN_TESTS == "YES" ]; then
25+ travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty;
26+ else
27+ travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty;
28+ fi
29+
30+ # Build Framework in Release and Run Tests if specified
31+ - if [ $RUN_TESTS == "YES" ]; then
32+ travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty;
33+ else
34+ travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO build | xcpretty;
35+ fi
36+
37+ # Build Example in Debug if specified
38+ - if [ $BUILD_EXAMPLE == "YES" ]; then
39+ travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$EXAMPLE_SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty;
40+ fi
41+
42+ # Build and report code coverage if specified
43+ - if [ $CODE_COV == "YES" ]; then
44+ xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=YES ENABLE_TESTABILITY=YES -enableCodeCoverage YES test;
45+ fi
46+
47+after_success:
48+ - bash <(curl -s https://codecov.io/bash)
49+
HueKit.podspecnew file+14
@@ -0,0 +1,14 @@
1+Pod::Spec.new do |s|
2+ s.name = 'HueKit'
3+ s.version = '1.0.0'
4+ s.license = 'MIT'
5+ s.summary = 'A UI framework for iOS that provides components and utilities for building color pickers.'
6+ s.homepage = 'https://github.com/louisdh/huekit'
7+ s.social_media_url = 'http://twitter.com/LouisDhauwe'
8+ s.authors = { 'Louis D\'hauwe' => 'louisdhauwe@silverfox.be' }
9+ s.source = { :git => 'https://github.com/louisdh/huekit.git', :tag => s.version }
10+
11+ s.ios.deployment_target = '10.0'
12+
13+ s.source_files = 'HueKit/**/*.swift'
14+end