preview what's going to jq

This commit is contained in:
Michał Rudowicz 2025-02-25 20:06:19 +01:00
parent 714f8a33a2
commit 29dccddd38
2 changed files with 3 additions and 4 deletions

View File

@ -6,7 +6,7 @@ jobs:
container: container:
image: git.hswro.org/fleg/actions-experiments:latest image: git.hswro.org/fleg/actions-experiments:latest
steps: steps:
- uses: https://codeberg.org/fleg/light-actions/checkout@test3 - uses: https://codeberg.org/fleg/light-actions/checkout@test4
- run: cat README.md - run: cat README.md
upload-artifact: upload-artifact:
runs-on: docker runs-on: docker
@ -14,7 +14,7 @@ jobs:
image: git.hswro.org/fleg/actions-experiments:latest image: git.hswro.org/fleg/actions-experiments:latest
steps: steps:
- run: echo "test passed" > test.txt - run: echo "test passed" > test.txt
- uses: https://codeberg.org/fleg/light-actions/upload-artifact@test3 - uses: https://codeberg.org/fleg/light-actions/upload-artifact@test4
with: with:
path: test.txt path: test.txt
artifact-name: test-artifact artifact-name: test-artifact

View File

@ -13,7 +13,6 @@ runs:
- run: | - run: |
set -euxo pipefail set -euxo pipefail
ARTIFACT_BASE="${ACTIONS_RUNTIME_URL}_apis/pipelines/workflows/${GITHUB_RUN_ID}/artifacts?api-version=6.0-preview" ARTIFACT_BASE="${ACTIONS_RUNTIME_URL}_apis/pipelines/workflows/${GITHUB_RUN_ID}/artifacts?api-version=6.0-preview"
echo test: ${ACTIONS_RUNTIME_TOKEN}
RESOURCE_URL="$( RESOURCE_URL="$(
curl \ curl \
-XPOST \ -XPOST \
@ -23,7 +22,7 @@ runs:
--header \"Authorization: Bearer ${ACTIONS_RUNTIME_TOKEN}\" \ --header \"Authorization: Bearer ${ACTIONS_RUNTIME_TOKEN}\" \
--header 'Content-Type: application/json' \ --header 'Content-Type: application/json' \
--data '{\"type\": \"actions_storage\", \"name\": \"${{ inputs.artifact-name }}\"}' \ --data '{\"type\": \"actions_storage\", \"name\": \"${{ inputs.artifact-name }}\"}' \
$ARTIFACT_BASE | jq --exit-status --raw-output .fileContainerResourceUrl $ARTIFACT_BASE | tee /dev/stderr | jq --exit-status --raw-output .fileContainerResourceUrl
)" )"
curl \ curl \