From 19297c73bc499ebc83be67fbff29f3e64b112316 Mon Sep 17 00:00:00 2001 From: Reda Lemeden Date: Thu, 22 Oct 2015 21:28:52 +0200 Subject: [PATCH] Add CircleCI config --- bin/carthage-bootstrap | 6 ++++++ bin/install-carthage | 6 ++++++ bin/setup | 3 +++ bin/test | 12 ++++++++++++ circle.yml | 16 ++++++++++++++++ 5 files changed, 43 insertions(+) create mode 100755 bin/carthage-bootstrap create mode 100755 bin/install-carthage create mode 100755 bin/setup create mode 100755 bin/test create mode 100755 circle.yml diff --git a/bin/carthage-bootstrap b/bin/carthage-bootstrap new file mode 100755 index 0000000..805dd06 --- /dev/null +++ b/bin/carthage-bootstrap @@ -0,0 +1,6 @@ +#!/usr/bin/env sh + +if ! diff Cartfile.resolved Carthage/Cartfile.resolved &>/dev/null; then + carthage bootstrap --platform iOS + cp Cartfile.resolved Carthage +fi diff --git a/bin/install-carthage b/bin/install-carthage new file mode 100755 index 0000000..ef89036 --- /dev/null +++ b/bin/install-carthage @@ -0,0 +1,6 @@ +#!/usr/bin/env sh + +version=0.9.3 + +curl -L -O "https://github.com/Carthage/Carthage/releases/download/$version/Carthage.pkg" +sudo installer -pkg Carthage.pkg -target / diff --git a/bin/setup b/bin/setup new file mode 100755 index 0000000..8786d66 --- /dev/null +++ b/bin/setup @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +bundle install diff --git a/bin/test b/bin/test new file mode 100755 index 0000000..a09c0f0 --- /dev/null +++ b/bin/test @@ -0,0 +1,12 @@ +#!/usr/bin/env sh + +set -o pipefail + +xcrun xcodebuild \ + -project Gifu.xcodeproj \ + -scheme Gifu \ + -sdk iphonesimulator \ + CONFIGURATION_BUILD_DIR='./build' \ + test \ + | xcpretty --color + diff --git a/circle.yml b/circle.yml new file mode 100755 index 0000000..2d5d27d --- /dev/null +++ b/circle.yml @@ -0,0 +1,16 @@ +machine: + xcode: + version: "7.0" + +dependencies: + pre: + - bin/install-carthage + override: + - bin/carthage-bootstrap + cache_directories: + - "Carthage" + - "build" + +test: + override: + - bin/test