diff options
| author | Ralf Kistner <ralf.kistner@gmail.com> | 2013-03-19 15:37:09 +0200 |
|---|---|---|
| committer | Ralf Kistner <ralf.kistner@gmail.com> | 2013-03-19 15:37:09 +0200 |
| commit | 53d10d02ba23223f5e8def4af8105023cf458c9b (patch) | |
| tree | 246b071957b1907312229566c5556567825bc49e | |
| parent | 446955917687d163e7b34e4977ce71089650c826 (diff) | |
Add travis configuration to verify a basic build.
| -rw-r--r-- | .travis.yml | 19 | ||||
| -rw-r--r-- | examples/empty/empty.ino | 9 | ||||
| -rwxr-xr-x | verify.sh | 22 |
3 files changed, 50 insertions, 0 deletions
diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..d3c9bd7 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,19 @@ +language: java +jdk: + - oraclejdk7 +env: + - ARDUINO_PACKAGE=arduino-1.5.2-linux64.tgz + - ARDUINO_PACKAGE=arduino-nightly-linux64.tgz +matrix: + - allow_failures: + - env: ARDUINO_PACKAGE=arduino-nightly-linux64.tgz +before_install: + #- wget http://downloads.arduino.cc/arduino-nightly-linux64.tgz + - wget http://downloads.arduino.cc/$ARDUINO_PACKAGE + - tar xzf $ARDUINO_PACKAGE + - export ARDUINO_PATH=$PWD/$ARDUINO_PACKAGE +script: + - ./verify.sh + + + diff --git a/examples/empty/empty.ino b/examples/empty/empty.ino new file mode 100644 index 0000000..f93cce6 --- /dev/null +++ b/examples/empty/empty.ino @@ -0,0 +1,9 @@ + +void setup() { + +} + +void loop() { + +} + diff --git a/verify.sh b/verify.sh new file mode 100755 index 0000000..d3109a6 --- /dev/null +++ b/verify.sh @@ -0,0 +1,22 @@ +#!/bin/bash +set -e + +EXAMPLES=$PWD/examples +ARDUINO="not found" + +if [[ ! -d "$ARDUINO_PATH" && -f "/usr/bin/arduino" ]]; then + ARDUINO_PATH=/usr/bin +fi + +function example { + if [[ -d "$ARDUINO_PATH" ]]; then + echo "Using $ARDUINO_PATH/arduino" + cd $ARDUINO_PATH + xvfb-run ./arduino --verify "$EXAMPLES/$1/$1.ino" + else + echo "Set $ARDUINO_PATH to the folder containing the arduino binary" + fi +} + +example "empty" + |
