Skip to content

Commit

Permalink
Add travis config files
Browse files Browse the repository at this point in the history
  • Loading branch information
kefniark committed Sep 21, 2016
1 parent d032027 commit 91691f9
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .travis.yml
@@ -0,0 +1,13 @@
# Example Travis config. See the entire example: https://github.com/JonathanPorta/ci-build

language: objective-c
osx_image: xcode61
rvm:
- 2.1.2
before_install:
- chmod a+x ./Scripts/install.sh
- chmod a+x ./Scripts/build.sh
install:
- ./Scripts/install.sh
script:
- ./Scripts/build.sh
7 changes: 7 additions & 0 deletions Scripts/build.sh
@@ -0,0 +1,7 @@
#! /bin/sh

echo "Run Unity Tests"
/Applications/Unity/Unity.app/Contents/MacOS/Unity -batchmode -runEditorTests -quit -projectPath $(pwd)

echo 'Logs from build'
cat $(pwd)/unity.log
29 changes: 29 additions & 0 deletions Scripts/install.sh
@@ -0,0 +1,29 @@
#! /bin/sh

BASE_URL=http://netstorage.unity3d.com/unity
HASH=e87ab445ead0
VERSION=5.3.2f1

download() {
file=$1
url="$BASE_URL/$HASH/$package"

echo "Downloading from $url: "
curl -o `basename "$package"` "$url"
}

install() {
package=$1
download "$package"

echo "Installing "`basename "$package"`
sudo installer -dumplog -package `basename "$package"` -target /
}

# See $BASE_URL/$HASH/unity-$VERSION-$PLATFORM.ini for complete list
# of available packages, where PLATFORM is `osx` or `win`

install "MacEditorInstaller/Unity-$VERSION.pkg"
install "MacEditorTargetInstaller/UnitySetup-Windows-Support-for-Editor-$VERSION.pkg"
install "MacEditorTargetInstaller/UnitySetup-Mac-Support-for-Editor-$VERSION.pkg"
install "MacEditorTargetInstaller/UnitySetup-Linux-Support-for-Editor-$VERSION.pkg"

0 comments on commit 91691f9

Please sign in to comment.