-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from skyweb07/feature/integrate-tracis-ci
Add travis CI integration
- Loading branch information
Showing
3 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/bash | ||
|
||
# Installs the SwiftLint package. | ||
# Tries to get the precompiled .pkg file from Github, but if that | ||
# fails just recompiles from source. | ||
|
||
set -e | ||
|
||
SWIFTLINT_PKG_PATH="/tmp/SwiftLint.pkg" | ||
SWIFTLINT_PKG_URL="https://github.com/realm/SwiftLint/releases/download/0.24.0/SwiftLint.pkg" | ||
|
||
wget --output-document=$SWIFTLINT_PKG_PATH $SWIFTLINT_PKG_URL | ||
|
||
if [ -f $SWIFTLINT_PKG_PATH ]; then | ||
echo "SwiftLint package exists! Installing it..." | ||
sudo installer -pkg $SWIFTLINT_PKG_PATH -target / | ||
else | ||
echo "SwiftLint package doesn't exist. Compiling from source..." && | ||
git clone https://github.com/realm/SwiftLint.git /tmp/SwiftLint && | ||
cd /tmp/SwiftLint && | ||
git submodule update --init --recursive && | ||
sudo make install | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
language: objective-c | ||
osx_image: xcode9.1 | ||
|
||
sudo: required | ||
install: | ||
- ./.scripts/install-swiftlint.sh | ||
|
||
script: | ||
- swiftlint | ||
- xcodebuild -scheme Snap -project ./Snap.xcodeproj -destination 'platform=iOS Simulator,name=iPhone 7' test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
</p> | ||
<h1 align="center">Snap.swift - Snapshot testing in a snap 🎨</h1> | ||
<p align="center"> | ||
<img src="https://travis-ci.org/skyweb07/Snap.swift.svg?branch=feature%2Fintegrate-tracis-ci"/> | ||
<img src="https://img.shields.io/badge/Swift-4.0-orange.svg" /> | ||
<a href="https://twitter.com/skyweb07"> | ||
<img src="https://img.shields.io/badge/[email protected]?style=flat" alt="Twitter: @skyweb07" /> | ||
|