File tree 3 files changed +21
-22
lines changed
3 files changed +21
-22
lines changed Original file line number Diff line number Diff line change @@ -23,16 +23,18 @@ function build(){
23
23
args+=" -i $chunk_index -m $chunks_cnt "
24
24
${BUILD_SKETCHES} ${args}
25
25
else
26
- if [ " $OS_IS_WINDOWS " == " 1" ]; then
27
- local ctags_version=` ls " $ARDUINO_IDE_PATH /tools-builder/ctags/" `
28
- local preprocessor_version=` ls " $ARDUINO_IDE_PATH /tools-builder/arduino-preprocessor/" `
29
- win_opts=" -prefs=runtime.tools.ctags.path=$ARDUINO_IDE_PATH /tools-builder/ctags/$ctags_version
30
- -prefs=runtime.tools.arduino-preprocessor.path=$ARDUINO_IDE_PATH /tools-builder/arduino-preprocessor/$preprocessor_version "
31
- args+=" -w \" ${win_opts} \" "
32
- fi
33
-
34
26
for sketch in ${sketches} ; do
35
- ${BUILD_SKETCH} ${args} " -s $( dirname $sketch ) "
27
+ echo $sketch
28
+ echo $( dirname $sketch )
29
+ args+=" -s $( dirname $sketch ) "
30
+ if [ " $OS_IS_WINDOWS " == " 1" ]; then
31
+ local ctags_version=` ls " $ARDUINO_IDE_PATH /tools-builder/ctags/" `
32
+ local preprocessor_version=` ls " $ARDUINO_IDE_PATH /tools-builder/arduino-preprocessor/" `
33
+ win_opts=" -prefs=runtime.tools.ctags.path=$ARDUINO_IDE_PATH /tools-builder/ctags/$ctags_version
34
+ -prefs=runtime.tools.arduino-preprocessor.path=$ARDUINO_IDE_PATH /tools-builder/arduino-preprocessor/$preprocessor_version "
35
+ args+=" \" ${win_opts} \" "
36
+ fi
37
+ ${BUILD_SKETCH} ${args}
36
38
done
37
39
fi
38
40
}
Original file line number Diff line number Diff line change @@ -24,18 +24,14 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
24
24
shift
25
25
target=$1
26
26
;;
27
- -s )
28
- shift
29
- sketchdir=$1
30
- ;;
31
- -w )
32
- shift
33
- win_opts=$1
34
- ;;
35
27
-fqbn )
36
28
shift
37
29
fqbn=$1
38
30
;;
31
+ -s )
32
+ shift
33
+ sketchdir=$1
34
+ ;;
39
35
-ff )
40
36
shift
41
37
ff_opt=$1
@@ -139,7 +135,8 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
139
135
rm -rf " $build_dir$i "
140
136
mkdir -p " $build_dir$i "
141
137
currfqbn=` echo $fqbn | jq -r --argjson i $i ' .[$i]' `
142
- echo " Building with FQBN=$currfqbn "
138
+ sketchname=$( basename $sketchdir )
139
+ echo " Building $sketchname with FQBN=$currfqbn "
143
140
$ide_path /arduino-builder -compile -logger=human -core-api-version=10810 \
144
141
-fqbn=\" $currfqbn \" \
145
142
-warnings=" all" \
@@ -151,7 +148,7 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
151
148
-libraries " $user_path /libraries" \
152
149
-build-cache " $ARDUINO_CACHE_DIR " \
153
150
-build-path " $build_dir$i " \
154
- $win_opts $ xtra_opts " ${sketchdir} /$( basename ${sketchdir} ) .ino"
151
+ $xtra_opts " ${sketchdir} /${sketchname} .ino"
155
152
done
156
153
}
157
154
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ function run_test() {
6
6
local options=$3
7
7
local erase_flash=$4
8
8
local sketchdir=$( dirname $sketch )
9
- local sketchdirname =$( basename $sketchdir )
9
+ local sketchname =$( basename $sketchdir )
10
10
11
11
if [ $options -eq 0 ] && [ -f $sketchdir /cfg.json ]; then
12
12
len=` jq -r --arg chip $target ' .targets[] | select(.name==$chip) | .fqbn | length' $sketchdir /cfg.json`
@@ -16,12 +16,12 @@ function run_test() {
16
16
17
17
for i in ` seq 0 $(( $len - 1 )) `
18
18
do
19
- echo " Running test: $sketchdirname -- Config: $i "
19
+ echo " Running test: $sketchname -- Config: $i "
20
20
if [ $erase_flash -eq 1 ]; then
21
21
esptool.py -c $target erase_flash
22
22
fi
23
23
24
- pytest tests --build-dir tests/$sketchdirname /build$i -k test_$sketchdirname --junit-xml=tests/$sketchdirname / $sketchdirname $i .xml
24
+ pytest tests --build-dir tests/$sketchname /build$i -k test_$sketchname --junit-xml=tests/$sketchname / $sketchname $i .xml
25
25
result=$?
26
26
if [ $result -ne 0 ]; then
27
27
return $result
You can’t perform that action at this time.
0 commit comments