Travis fix for ESP8266
This commit is contained in:
parent
8887bac07f
commit
d8350c7e5a
1 changed files with 23 additions and 6 deletions
29
.travis.yml
29
.travis.yml
|
@ -39,17 +39,34 @@ branches:
|
||||||
- master
|
- master
|
||||||
|
|
||||||
script:
|
script:
|
||||||
|
# set sketch skipping pattern for some boards
|
||||||
|
if [[ "$BOARD" =~ "esp8266:esp8266:" ]]; then
|
||||||
|
# on ESP8266, skip HTTP and MQTT examples
|
||||||
|
SKIP_PAT='(HTTP|MQTT).*ino'
|
||||||
|
else
|
||||||
|
# default skip pattern (matches everything)
|
||||||
|
SKIP_PAT='.*'
|
||||||
|
fi
|
||||||
|
|
||||||
# build all example sketches
|
# build all example sketches
|
||||||
- for example in $(find $PWD/examples -name '*.ino' | sort); do
|
- for example in $(find $PWD/examples -name '*.ino' | sort); do
|
||||||
echo -e "\n\033[1;33mBuilding ${example##*/} ... \033[0m";
|
# check whether to skip this sketch
|
||||||
arduino --verify --board $BOARD $example;
|
if [[ ${example} =~ $PAT2 ]]; then
|
||||||
if [ $? -ne 0 ]; then
|
# skip sketch
|
||||||
echo -e "\033[1;31m${example##*/} build FAILED\033[0m\n";
|
echo -e "\n\033[1;33mSkipped ${example##*/} (matched with $SKIP_PAT)\033[0m";
|
||||||
exit 1;
|
|
||||||
else
|
else
|
||||||
echo -e "\033[1;32m${example##*/} build PASSED\033[0m\n";
|
# build sketch
|
||||||
|
echo -e "\n\033[1;33mBuilding ${example##*/} ... \033[0m";
|
||||||
|
arduino --verify --board $BOARD $example;
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
echo -e "\033[1;31m${example##*/} build FAILED\033[0m\n";
|
||||||
|
exit 1;
|
||||||
|
else
|
||||||
|
echo -e "\033[1;32m${example##*/} build PASSED\033[0m\n";
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# generate Doxygen documentation (only for Arduino UNO)
|
# generate Doxygen documentation (only for Arduino UNO)
|
||||||
- if [ $BOARD = "arduino:avr:uno" ]; then
|
- if [ $BOARD = "arduino:avr:uno" ]; then
|
||||||
sudo apt-get update;
|
sudo apt-get update;
|
||||||
|
|
Loading…
Add table
Reference in a new issue