This repository was archived by the owner on Jan 22, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +11
-4
lines changed Expand file tree Collapse file tree 2 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -72,19 +72,25 @@ ARGS+=(
72
72
--env CI_JOB_ID
73
73
--env CI_PULL_REQUEST
74
74
--env CI_REPO_SLUG
75
- --env CODECOV_TOKEN
76
75
--env CRATES_IO_TOKEN
77
76
)
78
77
78
+ # Also propagate environment variables needed for codecov
79
+ # https://docs.codecov.io/docs/testing-with-docker#section-codecov-inside-docker
80
+ # We normalize CI to `1`; but codecov expects it to be `true` to detect Buildkite...
81
+ CODECOV_ENVS=$( CI=true bash <( curl -s https://codecov.io/env) )
82
+
79
83
if $INTERACTIVE ; then
80
84
if [[ -n $1 ]]; then
81
85
echo
82
86
echo " Note: '$* ' ignored due to --shell argument"
83
87
echo
84
88
fi
85
89
set -x
86
- exec docker run --interactive --tty " ${ARGS[@]} " " $IMAGE " bash
90
+ # shellcheck disable=SC2086
91
+ exec docker run --interactive --tty " ${ARGS[@]} " $CODECOV_ENVS " $IMAGE " bash
87
92
fi
88
93
89
94
set -x
90
- exec docker run " ${ARGS[@]} " " $IMAGE " " $@ "
95
+ # shellcheck disable=SC2086
96
+ exec docker run " ${ARGS[@]} " $CODECOV_ENVS " $IMAGE " " $@ "
Original file line number Diff line number Diff line change @@ -41,7 +41,8 @@ if [[ -z "$CODECOV_TOKEN" ]]; then
41
41
echo " ^^^ +++"
42
42
echo CODECOV_TOKEN undefined, codecov.io upload skipped
43
43
else
44
- bash <( curl -s https://codecov.io/bash) -X gcov -f target/cov/lcov.info
44
+ # We normalize CI to `1`; but codecov expects it to be `true` to detect Buildkite...
45
+ CI=true bash <( curl -s https://codecov.io/bash) -X gcov -f target/cov/lcov.info
45
46
46
47
annotate --style success --context codecov.io \
47
48
" CodeCov report: https://codecov.io/github/solana-labs/solana/commit/${CI_COMMIT: 0: 9} "
You can’t perform that action at this time.
0 commit comments