mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-19 23:22:16 +03:00
wip
This commit is contained in:
parent
bce2c99831
commit
c762de34f5
@ -78,7 +78,6 @@ jobs:
|
||||
# Deploy stage.
|
||||
# Here we build the package JSON (always) and do the deployments
|
||||
- name: "Package / deploy"
|
||||
if: type != pull_request
|
||||
stage: deploy
|
||||
script: $TRAVIS_BUILD_DIR/tests/common.sh
|
||||
env: BUILD_TYPE=package
|
||||
|
@ -127,19 +127,23 @@ cat $srcdir/package/package_esp8266com_index.template.json | \
|
||||
# Use Github API token, must be available
|
||||
curl_gh_token_arg=()
|
||||
if [ -z "$CI_GITHUB_API_KEY" ]; then
|
||||
echo "curl: API key not present, exit with error"
|
||||
exit 1
|
||||
fi
|
||||
echo "curl: API key not present"
|
||||
else
|
||||
echo "curl: API key is present"
|
||||
curl_gh_token_arg=(-H "Authorization: token $CI_GITHUB_API_KEY")
|
||||
|
||||
# test
|
||||
#echo "key was '$CI_GITHUB_API_KEY'"
|
||||
# this key (below) is working, the overwritten key is not empty
|
||||
#CI_GITHUB_API_KEY="vt6StBC+ghqnh8YrreNo3wAzGGddJ2S4YpVZkz4S84xLEGWkIEghQhTrjlhzjBsrnHfLNko4tz9EsNx0yQ8yBlPOdReETGAkqnAU7PSPFss0qGcCRUXYtozNjbFQq6TWIxECK4xq40R9tE6NyeOpm9AYJtwF/v18u2T+T9qSgGQ="
|
||||
fi
|
||||
|
||||
# Get previous release name
|
||||
echo "======== curl dumped header"
|
||||
curl --silent -D /dev/stderr ${curl_gh_token_arg[@]} https://api.github.com/repos/esp8266/Arduino/releases > releases.json
|
||||
if ! curl --silent -D /dev/stderr ${curl_gh_token_arg[@]} https://api.github.com/repos/esp8266/Arduino/releases > releases.json; then
|
||||
if [ -z "$CI_GITHUB_API_KEY" ]; then
|
||||
echo "---- Bad moon phase, in a PR, exit successfully"
|
||||
exit 0
|
||||
else
|
||||
echo "---- Please debug curl request, exit with error"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
echo "======== curl"
|
||||
|
||||
# Previous final release (prerelase == false)
|
||||
|
Loading…
x
Reference in New Issue
Block a user