Skip to content

Commit e8603fa

Browse files
fix: use double-quotes for OIDC (codecov#1669)
* fix: get log for use oidc * fix: add oidc run * fix: move the oidc call * fix: update to use double quote on oidc
1 parent 9c78078 commit e8603fa

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.github/workflows/main.yml

+8
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,14 @@ jobs:
7878
name: codecov-demo
7979
verbose: true
8080
token: ${{ secrets.CODECOV_TOKEN }}
81+
- name: Upload coverage to Codecov (oidc)
82+
uses: ./
83+
with:
84+
files: ./coverage/script/coverage-final.json
85+
flags: script,${{ matrix.os }}
86+
name: codecov-script
87+
use_oidc: true
88+
verbose: true
8189
- name: Upload coverage to Codecov (version)
8290
uses: ./
8391
with:

action.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ runs:
166166
if [ ${{ inputs.use_oidc }} == 'true' ];
167167
then
168168
# {"count":1984,"value":"***"}
169-
CC_TOKEN=$(curl -H "Authorization: bearer $ACTIONS_ID_TOKEN_REQUEST_TOKEN" "$ACTIONS_ID_TOKEN_REQUEST_URL&audience=api://AzureADTokenExchange" | cut -d\' -f6)
169+
CC_TOKEN=$(curl -H "Authorization: bearer $ACTIONS_ID_TOKEN_REQUEST_TOKEN" "$ACTIONS_ID_TOKEN_REQUEST_URL&audience=api://AzureADTokenExchange" | cut -d\" -f6)
170170
echo "CC_TOKEN=$CC_TOKEN" >> "$GITHUB_ENV"
171171
else
172172
if [ -n ${{ inputs.token }} ];

0 commit comments

Comments
 (0)