Skip to content

Commit 96a5db0

Browse files
committed
debug jq query
1 parent 6e67726 commit 96a5db0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.github/workflows/releasepublished.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,12 @@ jobs:
177177
rm start.xml
178178
curl --fail -H "Accept:application/json" -H "Authorization: Bearer ${{ secrets.PORTAL_ACCESS_TOKEN }}" 'https://ossrh-staging-api.central.sonatype.com/manual/search/repositories?state=open' -o results.json
179179
cat results.json
180+
cat results.json | jq --raw-output --arg SELECTOR "sdk-${{github.run_id}}-${{github.run_attempt}}" '.[][]
181+
cat results.json | jq --raw-output --arg SELECTOR "sdk-${{github.run_id}}-${{github.run_attempt}}" '.[][] | select(.description == "${SELECTOR}").key'
180182
cat results.json | jq --raw-output --arg SELECTOR "sdk-${{github.run_id}}-${{github.run_attempt}}" '.[][] | select(.description == "${SELECTOR}").key' | jq -sRr '@uri'
181183
repository_namespace=$(cat results.json | jq --raw-output --arg SELECTOR "sdk-${{github.run_id}}-${{github.run_attempt}}" '.[][] | select(.description == "${SELECTOR}").key' | jq -sRr '@uri')
182184
echo $repository_namespace
185+
rm results.json
183186
ls -lahn $WD
184187
cat $WD/finish.xml
185188
staging_dir=$(echo $(awk -F '[<>]' '/stagedRepositoryId/{print $3}' $WD/finish.xml))

0 commit comments

Comments
 (0)