Skip to content

Commit

Permalink
fix: use proper syntax for sending multiline strings to GitHub Action…
Browse files Browse the repository at this point in the history
…s output
  • Loading branch information
cybardev committed Jan 3, 2024
1 parent 60cb306 commit e5dce09
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,18 @@ jobs:
id: version_info
run: |
data=$(curl -sL https://api.github.com/repos/aseprite/aseprite/releases/latest)
LATEST_TAG=$(echo ${data} | jq -r '.tag_name')
DOWNLOAD_URL=$(echo ${data} | jq -r '.assets[].browser_download_url')
VERSION_INFO=$(echo ${data} | jq -r '.body')
LATEST_TAG=$(echo "${data}" | jq -r '.tag_name')
DOWNLOAD_URL=$(echo "${data}" | jq -r '.assets[].browser_download_url')
VERSION_INFO=$(echo "${data}" | jq -r '.body')
echo "${LATEST_TAG}" > ${LATEST_TAG}.txt
echo "latest_tag=${LATEST_TAG}" >> $GITHUB_OUTPUT
echo "download_url=${DOWNLOAD_URL}" >> $GITHUB_OUTPUT
echo "version_info=${VERSION_INFO}" >> $GITHUB_OUTPUT
echo "latest_tag=${LATEST_TAG}" >> "${GITHUB_OUTPUT}"
echo "download_url=${DOWNLOAD_URL}" >> "${GITHUB_OUTPUT}"
delimiter="$(openssl rand -hex 8)"
echo "version_info<<${delimiter}
echo "${VERSION_INFO}" >> "${GITHUB_OUTPUT}"
echo "${delimiter}" >> "${GITHUB_OUTPUT}"
- name: Load version from cache
id: version_check
uses: actions/cache@v2
Expand All @@ -43,7 +47,7 @@ jobs:
- name: Should we start new build?
id: should_build
if: steps.version_check.outputs.cache-hit != 'true'
run: echo "should_build=true" >> $GITHUB_OUTPUT
run: echo "should_build=true" >> "${GITHUB_OUTPUT}"
- name: Create Release
id: create_release
if: steps.should_build.outputs.should_build
Expand Down

0 comments on commit e5dce09

Please sign in to comment.