Skip to content

Commit

Permalink
Merge pull request #36 from mdiep/plain-xcodebuild
Browse files Browse the repository at this point in the history
Use plain xcodebuild instead of xctool
  • Loading branch information
mdiep authored Jul 22, 2016
2 parents 35aa712 + 2260a5a commit 144c215
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
15 changes: 9 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,15 @@ osx_image: xcode7.3
before_install:
- brew update
- brew outdated carthage || brew upgrade carthage
- brew uninstall xctool && brew install --HEAD xctool
before_script:
- carthage bootstrap --use-submodules --no-build
script: script/cibuild "$TRAVIS_XCODE_WORKSPACE" "$TRAVIS_XCODE_SCHEME"
script: script/cibuild "$TRAVIS_XCODE_WORKSPACE" "$TRAVIS_XCODE_SCHEME" "$XCODE_ACTION"
xcode_workspace: Tentacle.xcworkspace
xcode_scheme:
- Tentacle-OSX
- Tentacle-iOS
- update-test-fixtures
matrix:
include:
- xcode_scheme: Tentacle-OSX
env: XCODE_ACTION=test
- xcode_scheme: Tentacle-iOS
env: XCODE_ACTION=test
- xcode_scheme: update-test-fixtures
env: XCODE_ACTION=build
9 changes: 4 additions & 5 deletions script/cibuild
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,13 @@

use strict;

my ($WORKSPACE, $SCHEME) = @ARGV;
my ($WORKSPACE, $SCHEME, $ACTION) = @ARGV;

my $buildSettings = qx{xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -showBuildSettings};

my @args = ("-workspace", $WORKSPACE, "-scheme", $SCHEME, "test", "CODE_SIGNING_REQUIRED=NO", "CODE_SIGN_IDENTITY=");
my @args = ("-workspace", $WORKSPACE, "-scheme", $SCHEME, $ACTION, "CODE_SIGNING_REQUIRED=NO", "CODE_SIGN_IDENTITY=");

unshift @args, "-sdk", "iphonesimulator" if $buildSettings =~ /\bPLATFORM_NAME = iphoneos/i;

print "xctool @args\n";
exec("xctool", @args);

print "xcodebuild @args\n";
exec("xcodebuild", @args);

0 comments on commit 144c215

Please sign in to comment.