Skip to content

Commit 323bbbf

Browse files
authored
workflows/publish.yml: Run the workflow on success and failure only. (#6531)
* workflows/publish.yml: Run the workflow on success and failure only. This prevents trying to run when the trigger was cancelled or skipped. In these cases there will be no event file to upload. Signed-off-by: Abdelatif Guettouche <[email protected]> * scripts/sketch_utils.sh: Move the logic that gets the build dir after the part that retrieves the arguments. Signed-off-by: Abdelatif Guettouche <[email protected]> * workflows/hil.yml: Update the HIL runners tags. Signed-off-by: Abdelatif Guettouche <[email protected]> * workflows/hil.yml: Remove the Check Artifacts step. That was only useful for debugging. Signed-off-by: Abdelatif Guettouche <[email protected]>
1 parent 02f4178 commit 323bbbf

File tree

3 files changed

+17
-13
lines changed

3 files changed

+17
-13
lines changed

Diff for: .github/scripts/sketch_utils.sh

+9-6
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,22 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <fqbn> <path-to-i
77
return 1
88
fi
99

10-
ARDUINO_CACHE_DIR="$HOME/.arduino/cache.tmp"
11-
if [ -z "$ARDUINO_BUILD_DIR" ]; then
12-
build_dir="$(dirname $sketch)/build"
13-
else
14-
build_dir="$ARDUINO_BUILD_DIR"
15-
fi
1610
local ide_path=$1
1711
local usr_path=$2
1812
local fqbn=$3
1913
local sketch=$4
2014
local xtra_opts=$5
2115
local win_opts=$6
2216

17+
ARDUINO_CACHE_DIR="$HOME/.arduino/cache.tmp"
18+
if [ -z "$ARDUINO_BUILD_DIR" ]; then
19+
build_dir="$(dirname $sketch)/build"
20+
else
21+
build_dir="$ARDUINO_BUILD_DIR"
22+
fi
23+
24+
echo $sketch
25+
2326
rm -rf "$build_dir"
2427
mkdir -p "$build_dir"
2528
mkdir -p "$ARDUINO_CACHE_DIR"

Diff for: .github/workflows/hil.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,12 @@ jobs:
6767
Test:
6868
needs: [gen_chunks, Build]
6969
name: ${{matrix.chip}}-Test#${{matrix.chunks}}
70-
runs-on: ESP32
70+
runs-on:
71+
- ESP32
72+
- ESP32-S2
73+
- ESP32-S3
74+
- ESP32-C3
75+
7176
strategy:
7277
fail-fast: false
7378
matrix:
@@ -87,11 +92,6 @@ jobs:
8792
name: ${{matrix.chip}}-${{matrix.chunks}}.artifacts
8893
path: tests/
8994

90-
- name: Check Artifacts
91-
run: |
92-
ls -R tests
93-
cat tests/*/build/build.options.json
94-
9595
- name: Install dependencies
9696
run: |
9797
pip install -U pip

Diff for: .github/workflows/publish.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ jobs:
1414
runs-on: ubuntu-latest
1515
if: |
1616
github.event.workflow_run.event == 'pull_request' &&
17-
github.event.workflow_run.conclusion != 'skipped'
17+
(github.event.workflow_run.conclusion == 'success' ||
18+
(github.event.workflow_run.conclusion == 'failure')
1819
steps:
1920
- name: Download and Extract Artifacts
2021
env:

0 commit comments

Comments
 (0)