8000 igrr fix from feature/travis_jobs_tmp · arduino-collections/Arduino@2c45392 · GitHub
[go: up one dir, main page]

Skip to content

Commit 2c45392

Browse files
committed
igrr fix from feature/travis_jobs_tmp
1 parent 4169f88 commit 2c45392

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

package/build_boards_manager_package.sh

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,12 +134,18 @@ cat $srcdir/package/package_esp8266com_index.template.json | \
134134
jq "$jq_arg" > package_esp8266com_index.json
135135

136136
# Use Github API token, if available
137-
curl_gh_token_arg=()
137+
curl_gh_token_arg=""
138138
if [ ! -z "$CI_GITHUB_API_KEY" ]; then
139-
curl_gh_token_arg=(-H "Authorization: token $CI_GITHUB_API_KEY")
139+
echo "Authorization using CI_GITHUB_API_KEY"
140+
curl_gh_token_arg="-H \"Authorization: token $CI_GITHUB_API_KEY\""
141+
else
142+
echo "Warning: CI_GITHUB_API_KEY not set"
140143
fi
144+
echo "===================================="
145+
curl $curl_gh_token_arg -D - https://api.github.com/repos/esp8266/Arduino/releases
146+
echo "===================================="
141147
# Get previous release name
142-
curl --silent "${curl_gh_token_arg[@]}" https://api.github.com/repos/esp8266/Arduino/releases > releases.json
148+
curl --silent $curl_gh_token_arg https://api.github.com/repos/esp8266/Arduino/releases > releases.json
143149
# Previous final release (prerelase == false)
144150
prev_release=$(jq -r '. | map(select(.draft == false and .prerelease == false)) | sort_by(.created_at | - fromdateiso8601) | .[0].tag_name' releases.json)
145151
# Previous release (possibly a pre-release)

0 commit comments

Comments
 (0)
0