Skip to content

Commit

Permalink
Carthage Xcode 10.2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
mxcl committed Apr 7, 2019
1 parent 82a696c commit 15a5ab2
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 74 deletions.
102 changes: 40 additions & 62 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
os: osx
language: swift
osx_image: xcode10.2

branches:
only:
- master
stages:
- lint
- compile
- carthage
- swiftpm
- test
jobs:
include:
- &pod
stage: lint
osx_image: xcode8.3
env: SWIFT=3.1
name: pod lib lint --swift-version=3.1
os: osx
language: objective-c
cache:
- cocoapods
- directories:
Expand All @@ -31,89 +33,65 @@ jobs:
- <<: *pod
osx_image: xcode9.2
env: SWIFT=3.2
name: pod lib lint --swift-version=3.2
- <<: *pod
osx_image: xcode9.4
env: SWIFT=3.3
name: pod lib lint --swift-version=3.3
- <<: *pod
osx_image: xcode10
osx_image: xcode10.1
env: SWIFT=3.4
name: pod lib lint --swift-version=3.4
- <<: *pod
osx_image: xcode9.2
env: SWIFT=4.0
name: pod lib lint --swift-version=4.0
- <<: *pod
osx_image: xcode9.4
env: SWIFT=4.1
name: pod lib lint --swift-version=4.1
- <<: *pod
osx_image: xcode10
osx_image: xcode10.1
env: SWIFT=4.2
name: pod lib lint --swift-version=4.2

- stage: compile
osx_image: xcode10
name: Carthage / watchOS
os: osx
language: objective-c
script:
carthage bootstrap --platform watchOS
cache:
directories:
- <<: *pod
osx_image: xcode10.2
env: SWIFT=4.3
- <<: *pod
osx_image: xcode10.2
env: SWIFT=5.0

- &carthage
stage: carthage
osx_image: xcode9.2
script: |
carthage bootstrap --cache-builds
sed -i '' "s/SWIFT_TREAT_WARNINGS_AS_ERRORS = NO;/SWIFT_TREAT_WARNINGS_AS_ERRORS = YES;/" *.xcodeproj/project.pbxproj
carthage build --no-skip-current
cache.directories:
- Carthage

# Alamofire does not yet support Linux
# - &linux
# stage: compile
# env: SWIFT_BUILD_VERSION=3 SWIFT_VERSION=4.0.3
# name: Linux / Swift 3.2.3
# os: linux
# dist: trusty
# sudo: required
# language: generic
# before_install:
# eval "$(curl -sL https://swiftenv.fuller.li/install.sh)"
# script:
# swift build -Xswiftc -swift-version -Xswiftc $SWIFT_BUILD_VERSION
# - <<: *linux
# env: SWIFT_BUILD_VERSION=4 SWIFT_VERSION=4.2.1
# name: Linux / Swift 4.2.1
- <<: *carthage
osx_image: xcode9.4
- <<: *carthage
osx_image: xcode10.1
- <<: *carthage
osx_image: xcode10.2

- &swiftpm
stage: compile
name: Xcode 8.3 / SwiftPM
os: osx
stage: swiftpm
osx_image: xcode8.3
language: objective-c
script: swift build
- <<: *swiftpm
name: Xcode 9.4 / SwiftPM
osx_image: xcode9.4
- <<: *swiftpm
name: Xcode 10.1 / SwiftPM
osx_image: xcode10
osx_image: xcode10.1
- <<: *swiftpm
osx_image: xcode10.2

- &test
stage: test
osx_image: xcode10
name: macOS Tests
env: DST='arch=x86_64' PLAT=macOS
os: osx
language: objective-c
cache:
directories:
xcode_scheme: PMKAlamofire
xcode_project: PMKAlamofire.xcodeproj
xcode_destination: 'platform=macOS'
cache.directories:
- Carthage
before_install:
carthage bootstrap --cache-builds --no-use-binaries --platform $PLAT
install:
xcodebuild -scheme PMKAlamofire -target PMKAlamofire -quiet -destination "$DST" SWIFT_TREAT_WARNINGS_AS_ERRORS=YES build
script:
xcodebuild -scheme PMKAlamofire -quiet -destination "$DST" test
carthage bootstrap --cache-builds --no-use-binaries
- <<: *test
env: DST='OS=12.0,name=iPhone SE' PLAT=iOS
name: iOS Tests
xcode_destination: 'platform=iOS Simulator,OS=12.2,name=iPhone SE'
- <<: *test
env: DST='OS=12.0,name=Apple TV' PLAT=tvOS
name: tvOS Tests
xcode_destination: 'platform=tvOS Simulator,OS=12.2,name=Apple TV'
2 changes: 1 addition & 1 deletion Cartfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github "mxcl/PromiseKit" ~> 6.0
github "mxcl/PromiseKit" ~> 6.8.4
github "Alamofire/Alamofire" ~> 4.0
2 changes: 1 addition & 1 deletion Cartfile.private
Original file line number Diff line number Diff line change
@@ -1 +1 @@
github "AliSoftware/OHHTTPStubs" ~> 6.0
github "AliSoftware/OHHTTPStubs" ~> 7.0
4 changes: 2 additions & 2 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
github "Alamofire/Alamofire" "4.8.1"
github "AliSoftware/OHHTTPStubs" "6.2.0"
github "Alamofire/Alamofire" "4.8.2"
github "AliSoftware/OHHTTPStubs" "7.0.0"
github "mxcl/PromiseKit" "6.8.4"
17 changes: 10 additions & 7 deletions PMKAlamofire.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@
63C7FF9D1D5BEE09003BAE60 = {
isa = PBXGroup;
children = (
63C700091D5C0253003BAE60 /* Info.plist */,
63CCF8121D5C0C4E00503216 /* Cartfile */,
63CCF8131D5C0C4E00503216 /* Cartfile.private */,
63CCF8171D5C11B500503216 /* Carthage.xcconfig */,
63C700091D5C0253003BAE60 /* Info.plist */,
63C7FFA91D5BEE09003BAE60 /* Sources */,
63C7FFF31D5C020D003BAE60 /* Tests */,
63C7FFA81D5BEE09003BAE60 /* Products */,
Expand Down Expand Up @@ -145,27 +145,28 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0800;
LastUpgradeCheck = 0930;
LastUpgradeCheck = 1020;
ORGANIZATIONNAME = "Max Howell";
TargetAttributes = {
63C7FFA61D5BEE09003BAE60 = {
CreatedOnToolsVersion = 8.0;
LastSwiftMigration = 0900;
LastSwiftMigration = 1020;
ProvisioningStyle = Automatic;
};
63C7FFF11D5C020D003BAE60 = {
CreatedOnToolsVersion = 8.0;
LastSwiftMigration = 0900;
LastSwiftMigration = 1020;
ProvisioningStyle = Automatic;
};
};
};
buildConfigurationList = 63C7FFA11D5BEE09003BAE60 /* Build configuration list for PBXProject "PMKAlamofire" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 63C7FF9D1D5BEE09003BAE60;
productRefGroup = 63C7FFA81D5BEE09003BAE60 /* Products */;
Expand Down Expand Up @@ -231,6 +232,7 @@
baseConfigurationReference = 63CCF8171D5C11B500503216 /* Carthage.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
Expand Down Expand Up @@ -299,6 +301,7 @@
baseConfigurationReference = 63CCF8171D5C11B500503216 /* Carthage.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
Expand Down Expand Up @@ -369,6 +372,7 @@
PRODUCT_MODULE_NAME = "${TARGET_NAME}";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_TREAT_WARNINGS_AS_ERRORS = NO;
};
name = Debug;
};
Expand All @@ -385,6 +389,7 @@
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_MODULE_NAME = "${TARGET_NAME}";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_TREAT_WARNINGS_AS_ERRORS = NO;
};
name = Release;
};
Expand All @@ -398,7 +403,6 @@
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_SUPPRESS_WARNINGS = YES;
SWIFT_VERSION = 4.0;
};
name = Debug;
};
Expand All @@ -411,7 +415,6 @@
"LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_SUPPRESS_WARNINGS = YES;
SWIFT_VERSION = 4.0;
};
name = Release;
};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0930"
LastUpgradeVersion = "1020"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down

0 comments on commit 15a5ab2

Please sign in to comment.