Merge pull request #912 from keyboardio/f/travis-reporting-cleanup

Rework our travis config.
pull/915/head
Gergely Nagy 4 years ago committed by GitHub
commit 25f0d2fc66
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,5 +1,4 @@
dist: bionic
sudo: false
dist: focal
language: c
os:
- linux
@ -11,26 +10,35 @@ addons:
env:
global:
- LC_ALL: C
git:
quiet: true
before_install:
- ccache --set-config=compiler_check=content -M 5G -F 0
install:
- git clone --depth 1 --recurse-submodules https://github.com/keyboardio/Kaleidoscope-Bundle-Keyboardio ../hardware/keyboardio
## We delete the Bundle's version of Kaleidoscope, and symlink ourselves in.
## This makes sure we're using the current version of the library.
- rm -rf ../hardware/keyboardio/avr/libraries/Kaleidoscope
- ln -s $(pwd) ../hardware/keyboardio/avr/libraries/Kaleidoscope
jobs:
include:
- env: TEST_TARGET=travis-smoke-examples
- env: TEST_TARGET=travis-simulator-tests
- env: TEST_TARGET=cpplint
- env: TEST_TARGET=find-filename-conflicts
- env: TEST_TARGET=shellcheck
- env: TEST_TARGET=travis-check-astyle
script:
- unset CC
- make cpplint BOARD_HARDWARE_PATH=$(pwd)/../hardware
- make travis-install-arduino BOARD_HARDWARE_PATH=$(pwd)/../hardware
- (cd ../hardware/keyboardio && make prepare-virtual)
- make -C tests all BOARD_HARDWARE_PATH=$(pwd)/../hardware ARDUINO_PATH="$(pwd)/arduino-1.8.13"
- rm -rf .kaleidoscope-build-cache
- make travis-test KALEIDOSCOPE_TEMP_PATH=$(pwd)/.kaleidoscope-build-cache BOARD_HARDWARE_PATH=$(pwd)/../hardware
- make $TEST_TARGET KALEIDOSCOPE_TEMP_PATH=$(pwd)/.kaleidoscope-build-cache BOARD_HARDWARE_PATH=$(pwd)/../hardware ARDUINO_PATH="$(pwd)/arduino-1.8.13"
notifications:
email:
on_success: change
on_failure: change
cache:
apt: true
ccache: true
directories:
- .download-cache
- .kaleidoscope-build-cache
- .ccache

@ -19,6 +19,12 @@ set -e
###### Build and output configuration
######
absolute_filename() {
echo "$(cd "$(dirname "$1")" && pwd)/$(basename "$1")"
}
build_version () {
GIT_VERSION="$(cd "$(find_sketch)"; if [ -d .git ]; then echo -n '-g' && git describe --abbrev=4 --dirty --always; fi)"
LIB_PROPERTIES_PATH="${LIB_PROPERTIES_PATH:-"../.."}"
@ -26,9 +32,9 @@ build_version () {
}
build_paths() {
# We don't really want to use find
# shellcheck disable=SC2012
SKETCH_IDENTIFIER="$(ls -id "$(find_sketch)/${SKETCH}.ino" | cut -d ' ' -f 1)-${SKETCH}.ino"
# We need that echo because we\re piping to cksum
# shellcheck disable=SC2005
SKETCH_IDENTIFIER="$(echo "$(absolute_filename "$(find_sketch)/${SKETCH}.ino")" | cksum | cut -d ' ' -f 1)-${SKETCH}.ino"
KALEIDOSCOPE_TEMP_PATH="${KALEIDOSCOPE_TEMP_PATH:-${TMPDIR:-/tmp}/kaleidoscope-${USER}}"
@ -345,7 +351,7 @@ compile () {
SKETCH_DIR="$(find_sketch)"
echo "Building ${SKETCH_DIR}/${SKETCH} ${LIB_VERSION} into ${OUTPUT_PATH}"
echo "Building ${SKETCH_DIR}/${SKETCH}"
# This is defined in the (optional) user config.
# shellcheck disable=SC2154

Loading…
Cancel
Save