Skip to content

Commit 0180326

Browse files
committed
For CI builds get branch from env
1 parent cd5d3b2 commit 0180326

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tools/update-components.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,11 @@ if [ ! -d "$AR_COMPS/arduino" ]; then
1818
fi
1919

2020
if [ -z $AR_BRANCH ]; then
21-
current_branch=`git branch --show-current`
21+
if [ -z $GITHUB_REF_NAME ]; then
22+
current_branch="$GITHUB_REF_NAME"
23+
else
24+
current_branch=`git branch --show-current`
25+
fi
2226
if [[ "$current_branch" != "master" && `git_branch_exists "$AR_COMPS/arduino" "$current_branch"` == "1" ]]; then
2327
export AR_BRANCH="$current_branch"
2428
else

0 commit comments

Comments
 (0)