File tree Expand file tree Collapse file tree 1 file changed +33
-4
lines changed Expand file tree Collapse file tree 1 file changed +33
-4
lines changed Original file line number Diff line number Diff line change 21
21
REPOSITORY_URL=" https://github.com/${CIRCLE_PROJECT_USERNAME} /${CIRCLE_PROJECT_REPONAME} "
22
22
COMMIT_URL=" ${REPOSITORY_URL} /commit/${CIRCLE_SHA1} "
23
23
24
- # Underscores are treated as italic styling and seems to cause an error
25
- export CIRCLE_BRANCH=" ${CIRCLE_BRANCH// _/ \\ _} "
26
-
27
24
BASE_BLOCK=$( cat << EOF
28
25
{
29
26
"type": "section",
@@ -55,8 +52,9 @@ if [ "${RESULT_STATUS}" == "failed" ]; then
55
52
EOF
56
53
)
57
54
55
+ # Do not add new platforms here, there is a limit of 10 currently, see a block below instead
58
56
fields=" "
59
- for p in Argon Boron BSoM B5SoM Tracker TrackerM ESomX P2 GCC Newhal P2 ; do
57
+ for p in Argon Boron BSoM B5SoM Tracker TrackerM ESomX P2 GCC Newhal; do
60
58
if echo -e " ${failures} " | grep -q " PLATFORM=\" ${p,,} \" " ; then
61
59
msg=" :scrum_closed: $p \\ n"
62
60
else
85
83
EOF
86
84
)
87
85
86
+ fields=" "
87
+ for p in P2; do
88
+ if echo -e " ${failures} " | grep -q " PLATFORM=\" ${p,,} \" " ; then
89
+ msg=" :scrum_closed: $p \\ n"
90
+ else
91
+ msg=" :scrum_finished: $p \\ n"
92
+ fi
93
+ field=$( cat << EOF
94
+ {
95
+ "type": "mrkdwn",
96
+ "text": "${msg} "
97
+ }
98
+ EOF
99
+ )
100
+ comma=" ,"
101
+ if [ " ${fields} " == " " ]; then
102
+ comma=" "
103
+ fi
104
+ fields=" ${fields}${comma}${field} "
105
+ done
106
+ ADDITIONAL_BLOCKS+=$( cat << EOF
107
+ ,{
108
+ "type": "section",
109
+ "fields": [
110
+ ${fields}
111
+ ]
112
+ }
113
+ EOF
114
+ )
115
+
116
+
88
117
if [ " ${CIRCLE_ARTIFACTS_URL} " == " " ]; then
89
118
msg=" :scrum_closed: Artifacts"
90
119
else
You can’t perform that action at this time.
0 commit comments