mirror of
				https://github.com/eledio-devices/thirdparty-ArduinoJson.git
				synced 2025-10-31 16:14:11 +01:00 
			
		
		
		
	CI: build with arduino-cli
This commit is contained in:
		
							
								
								
									
										38
									
								
								.github/workflows/ci.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										38
									
								
								.github/workflows/ci.yml
									
									
									
									
										vendored
									
									
								
							| @@ -211,20 +211,40 @@ jobs: | |||||||
|       fail-fast: false |       fail-fast: false | ||||||
|       matrix: |       matrix: | ||||||
|         include: |         include: | ||||||
|           - arduino: "1.6.7" |           - core: arduino:avr | ||||||
|             os: ubuntu-18.04 # java.lang.Error: Cannot load com.sun.java.swing.plaf.gtk.GTKLookAndFeel |  | ||||||
|             board: arduino:avr:uno |             board: arduino:avr:uno | ||||||
|           - arduino: "1.8.2" |           - core: arduino:samd | ||||||
|             board: arduino:samd:mkr1000 |             board: arduino:samd:mkr1000 | ||||||
|     runs-on: ${{ matrix.os || 'ubuntu-latest' }} |     runs-on: ubuntu-20.04 | ||||||
|     steps: |     steps: | ||||||
|       - name: Checkout |       - name: Checkout | ||||||
|         uses: actions/checkout@v2 |         uses: actions/checkout@v2 | ||||||
|       - name: Build |       - name: Install arduino-cli | ||||||
|         run: extras/ci/arduino.sh ${{ matrix.board }} |         run: brew update && brew install arduino-cli | ||||||
|         env: |       - name: Install core | ||||||
|           BOARD: ${{ matrix.board }} |         run: arduino-cli core install ${{ matrix.core }} | ||||||
|           VERSION: ${{ matrix.arduino }} |       - name: Install libraries | ||||||
|  |         run: arduino-cli lib install SD Ethernet | ||||||
|  |       - name: Build JsonConfigFile | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonConfigFile/JsonConfigFile.ino" | ||||||
|  |       - name: Build JsonFilterExample | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonFilterExample/JsonFilterExample.ino" | ||||||
|  |       - name: Build JsonGeneratorExample | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonGeneratorExample/JsonGeneratorExample.ino" | ||||||
|  |       - name: Build JsonHttpClient | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonHttpClient/JsonHttpClient.ino" | ||||||
|  |       - name: Build JsonParserExample | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonParserExample/JsonParserExample.ino" | ||||||
|  |       - name: Build JsonServer | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonServer/JsonServer.ino" | ||||||
|  |       - name: Build JsonUdpBeacon | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/JsonUdpBeacon/JsonUdpBeacon.ino" | ||||||
|  |       - name: Build MsgPackParser | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/MsgPackParser/MsgPackParser.ino" | ||||||
|  |       - name: Build ProgmemExample | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/ProgmemExample/ProgmemExample.ino" | ||||||
|  |       - name: Build StringExample | ||||||
|  |         run: arduino-cli compile --library . --warnings all -b ${{ matrix.board }} "examples/StringExample/StringExample.ino" | ||||||
|  |  | ||||||
|   platformio: |   platformio: | ||||||
|     name: PlatformIO |     name: PlatformIO | ||||||
|   | |||||||
| @@ -1,20 +0,0 @@ | |||||||
| #!/bin/bash -eux |  | ||||||
|  |  | ||||||
| /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_1.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :1 -ac -screen 0 1280x1024x16 |  | ||||||
| sleep 3 |  | ||||||
| export DISPLAY=:1.0 |  | ||||||
|  |  | ||||||
| mkdir -p /tmp/arduino |  | ||||||
| curl -sS http://downloads.arduino.cc/arduino-$VERSION-linux64.tar.xz | tar xJ -C /tmp/arduino --strip 1 || |  | ||||||
| curl -sS http://downloads.arduino.cc/arduino-$VERSION-linux64.tgz | tar xz -C /tmp/arduino --strip 1 |  | ||||||
| export PATH=$PATH:/tmp/arduino/ |  | ||||||
|  |  | ||||||
| if [[ "$BOARD" =~ "arduino:samd:" ]]; then |  | ||||||
|   arduino --install-boards arduino:samd |  | ||||||
| fi |  | ||||||
|  |  | ||||||
| ln -s $PWD /tmp/arduino/libraries/ArduinoJson |  | ||||||
|  |  | ||||||
| for EXAMPLE in $PWD/examples/*/*.ino; do |  | ||||||
| 	arduino --verify --board $BOARD $EXAMPLE |  | ||||||
| done |  | ||||||
		Reference in New Issue
	
	Block a user