2
2
3
3
source ./tools/config.sh
4
4
5
- CAMERA_REPO_URL=" https://github.com/tasmota/esp32-camera.git"
5
+ CAMERA_REPO_URL=" https://github.com/espressif/esp32-camera.git"
6
+ DL_REPO_URL=" https://github.com/espressif/esp-dl.git"
7
+ SR_REPO_URL=" https://github.com/espressif/esp-sr.git"
6
8
DSP_REPO_URL=" https://github.com/espressif/esp-dsp.git"
7
9
LITTLEFS_REPO_URL=" https://github.com/joltwallet/esp_littlefs.git"
8
10
TINYUSB_REPO_URL=" https://github.com/hathach/tinyusb.git"
@@ -16,19 +18,31 @@ if [ ! -d "$AR_COMPS/arduino" ]; then
16
18
fi
17
19
18
20
if [ -z $AR_BRANCH ]; then
19
- has_ar_branch=` git_branch_exists " $AR_COMPS /arduino" " idf-$IDF_BRANCH " `
20
- if [ " $has_ar_branch " == " 1" ]; then
21
- export AR_BRANCH=" idf-$IDF_BRANCH "
21
+ if [ -z $GITHUB_HEAD_REF ]; then
22
+ current_branch=` git branch --show-current`
22
23
else
23
- has_ar_branch=` git_branch_exists " $AR_COMPS /arduino" " $AR_PR_TARGET_BRANCH " `
24
+ current_branch=" $GITHUB_HEAD_REF "
25
+ fi
26
+ echo " Current Branch: $current_branch "
27
+ if [[ " $current_branch " != " master" && ` git_branch_exists " $AR_COMPS /arduino" " $current_branch " ` == " 1" ]]; then
28
+ export AR_BRANCH=" $current_branch "
29
+ else
30
+ has_ar_branch=` git_branch_exists " $AR_COMPS /arduino" " idf-$IDF_BRANCH " `
24
31
if [ " $has_ar_branch " == " 1" ]; then
25
- export AR_BRANCH=" $AR_PR_TARGET_BRANCH "
32
+ export AR_BRANCH=" idf-$IDF_BRANCH "
33
+ else
34
+ has_ar_branch=` git_branch_exists " $AR_COMPS /arduino" " $AR_PR_TARGET_BRANCH " `
35
+ if [ " $has_ar_branch " == " 1" ]; then
36
+ export AR_BRANCH=" $AR_PR_TARGET_BRANCH "
37
+ fi
26
38
fi
27
39
fi
28
40
fi
29
41
30
42
if [ " $AR_BRANCH " ]; then
31
- git -C " $AR_COMPS /arduino" checkout " $AR_BRANCH "
43
+ git -C " $AR_COMPS /arduino" checkout " $AR_BRANCH " && \
44
+ git -C " $AR_COMPS /arduino" fetch && \
45
+ git -C " $AR_COMPS /arduino" pull --ff-only
32
46
fi
33
47
if [ $? -ne 0 ]; then exit 1; fi
34
48
@@ -48,6 +62,30 @@ if [ -f "$AR_COMPS/esp32-camera/idf_component.yml" ]; then
48
62
fi
49
63
if [ $? -ne 0 ]; then exit 1; fi
50
64
65
+ #
66
+ # CLONE/UPDATE ESP-DL
67
+ #
68
+
69
+ # if [ ! -d "$AR_COMPS/esp-dl" ]; then
70
+ # git clone $DL_REPO_URL "$AR_COMPS/esp-dl"
71
+ # else
72
+ # git -C "$AR_COMPS/esp-dl" fetch && \
73
+ # git -C "$AR_COMPS/esp-dl" pull --ff-only
74
+ # fi
75
+ # if [ $? -ne 0 ]; then exit 1; fi
76
+
77
+ #
78
+ # CLONE/UPDATE ESP-SR
79
+ #
80
+
81
+ # if [ ! -d "$AR_COMPS/esp-sr" ]; then
82
+ # git clone $SR_REPO_URL "$AR_COMPS/esp-sr"
83
+ # else
84
+ # git -C "$AR_COMPS/esp-sr" fetch && \
85
+ # git -C "$AR_COMPS/esp-sr" pull --ff-only
86
+ # fi
87
+ # if [ $? -ne 0 ]; then exit 1; fi
88
+
51
89
#
52
90
# CLONE/UPDATE ESP-LITTLEFS
53
91
#
@@ -68,10 +106,10 @@ if [ $? -ne 0 ]; then exit 1; fi
68
106
69
107
if [ ! -d " $AR_COMPS /esp-dsp" ]; then
70
108
git clone $DSP_REPO_URL " $AR_COMPS /esp-dsp"
71
- cml=` cat " $AR_COMPS /esp-dsp/CMakeLists.txt" `
72
- echo " if(IDF_TARGET STREQUAL \" esp32\" OR IDF_TARGET STREQUAL \" esp32s2\" OR IDF_TARGET STREQUAL \" esp32s3\" )" > " $AR_COMPS /esp-dsp/CMakeLists.txt"
73
- echo " $cml " >> " $AR_COMPS /esp-dsp/CMakeLists.txt"
74
- echo " endif()" >> " $AR_COMPS /esp-dsp/CMakeLists.txt"
109
+ # cml=`cat "$AR_COMPS/esp-dsp/CMakeLists.txt"`
110
+ # echo "if(IDF_TARGET STREQUAL \"esp32\" OR IDF_TARGET STREQUAL \"esp32s2\" OR IDF_TARGET STREQUAL \"esp32s3\")" > "$AR_COMPS/esp-dsp/CMakeLists.txt"
111
+ # echo "$cml" >> "$AR_COMPS/esp-dsp/CMakeLists.txt"
112
+ # echo "endif()" >> "$AR_COMPS/esp-dsp/CMakeLists.txt"
75
113
else
76
114
git -C " $AR_COMPS /esp-dsp" fetch && \
77
115
git -C " $AR_COMPS /esp-dsp" pull --ff-only
0 commit comments