mirror of
https://github.com/Links2004/arduinoWebSockets.git
synced 2025-07-23 12:27:13 +02:00
update github actions to arduino-cli for build tests
This commit is contained in:
@ -29,6 +29,22 @@ function build_sketches()
|
||||
done
|
||||
}
|
||||
|
||||
function build_sketch_cli()
|
||||
{
|
||||
local sketch=$1
|
||||
local board=$2
|
||||
arduino-cli --log --log-level info compile -b "$board" "$sketch"
|
||||
if [ $result -ne 0 ]; then
|
||||
echo "Build failed ($sketch) build verbose..."
|
||||
arduino-cli --log --log-level debug compile -b "$board" "$sketch"
|
||||
result=$?
|
||||
fi
|
||||
if [ $result -ne 0 ]; then
|
||||
echo "Build failed ($1) $sketch"
|
||||
return $result
|
||||
fi
|
||||
}
|
||||
|
||||
function build_sketch()
|
||||
{
|
||||
local arduino=$1
|
||||
@ -88,11 +104,19 @@ function get_sketches_json_matrix()
|
||||
done
|
||||
}
|
||||
|
||||
function get_core_cli() {
|
||||
arduino-cli core update-index --additional-urls https://arduino.esp8266.com/stable/package_esp8266com_index.json,https://espressif.github.io/arduino-esp32/package_esp32_index.json,https://github.com/earlephilhower/arduino-pico/releases/download/global/package_rp2040_index.json
|
||||
arduino-cli core install esp8266:esp8266
|
||||
arduino-cli core install esp32:esp32
|
||||
arduino-cli core install arduino:mbed_rp2040
|
||||
}
|
||||
|
||||
function get_core()
|
||||
{
|
||||
echo Setup core for $1
|
||||
|
||||
cd $HOME/arduino_ide/hardware
|
||||
mkdir -p $HOME/arduino_ide/packages/hardware
|
||||
cd $HOME/arduino_ide/packages/hardware
|
||||
|
||||
if [ "$1" = "esp8266" ] ; then
|
||||
mkdir esp8266com
|
||||
|
Reference in New Issue
Block a user