Skip to content

Commit 6bee53a

Browse files
authored
github actions test
1 parent ebb87cd commit 6bee53a

File tree

1 file changed

+50
-0
lines changed

1 file changed

+50
-0
lines changed

.github/workflows/main.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: CI
4+
5+
# Controls when the action will run.
6+
on:
7+
# Triggers the workflow on push or pull request events but only for the master branch
8+
push:
9+
branches: [ master ]
10+
pull_request:
11+
branches: [ master ]
12+
13+
# Allows you to run this workflow manually from the Actions tab
14+
workflow_dispatch:
15+
16+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
17+
jobs:
18+
# This workflow contains a single job called "build"
19+
build:
20+
# The type of runner that the job will run on
21+
runs-on: ubuntu-latest
22+
23+
# Steps represent a sequence of tasks that will be executed as part of the job
24+
steps:
25+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
26+
- uses: actions/checkout@v2
27+
28+
- name: build examples
29+
run: |
30+
/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_1.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :1 -ac -screen 0 1280x1024x16
31+
export DISPLAY=:1.0
32+
sleep 3
33+
wget http://downloads.arduino.cc/arduino-$IDE_VERSION-linux64.tar.xz
34+
tar xf arduino-$IDE_VERSION-linux64.tar.xz
35+
mv arduino-$IDE_VERSION $HOME/arduino_ide
36+
export PATH="$HOME/arduino_ide:$PATH"
37+
which arduino
38+
mkdir -p $HOME/Arduino/libraries
39+
40+
wget https://github.com/bblanchon/ArduinoJson/archive/6.x.zip
41+
unzip 6.x.zip
42+
mv ArduinoJson-6.x $HOME/Arduino/libraries/ArduinoJson
43+
cp -r $GITHUB_WORKSPACE $HOME/Arduino/libraries/arduinoWebSockets
44+
source $GITHUB_WORKSPACE/travis/common.sh
45+
get_core $CPU
46+
cd $GITHUB_WORKSPACE
47+
arduino --board $BOARD --save-prefs
48+
arduino --get-pref sketchbook.path
49+
arduino --pref update.check=false
50+
build_sketches arduino $HOME/Arduino/libraries/arduinoWebSockets/examples/$CPU $CPU

0 commit comments

Comments
 (0)