Skip to content

Commit 168e236

Browse files
committed
.github: Fix building chunks.
Multiple arguments and options were not set correctly. Signed-off-by: Abdelatif Guettouche <[email protected]>
1 parent 1d107aa commit 168e236

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

.github/scripts/on-push.sh

+4-5
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ function build(){
1616

1717
local args="-ai $ARDUINO_IDE_PATH -au $ARDUINO_USR_PATH"
1818

19-
args+=" -fqbn $fqbn"
19+
args+=" -t $target -fqbn $fqbn"
2020

2121
if [ "$OS_IS_LINUX" == "1" ]; then
22-
args+=" $ARDUINO_ESP32_PATH/libraries"
23-
args+=" $chunk_index $chunks_cnt"
22+
args+=" -p $ARDUINO_ESP32_PATH/libraries"
23+
args+=" -i $chunk_index -m $chunks_cnt"
2424
${BUILD_SKETCHES} ${args}
2525
else
2626
if [ "$OS_IS_WINDOWS" == "1" ]; then
@@ -32,8 +32,7 @@ function build(){
3232
fi
3333

3434
for sketch in ${sketches}; do
35-
args+=" -s $sketch"
36-
${BUILD_SKETCH} ${args}
35+
${BUILD_SKETCH} ${args} " -s $sketch"
3736
done
3837
fi
3938
}

.github/scripts/sketch_utils.sh

+5
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,11 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
114114
fqbn+=$opts
115115
fqbn="[\"$fqbn\"]"
116116
fi
117+
else
118+
# An FQBN was passed. Make it look like a JSON array.
119+
120+
len=1
121+
fqbn="[\"$fqbn\"]"
117122
fi
118123

119124
if [ -z "$fqbn" ]; then

0 commit comments

Comments
 (0)