Skip to content

Commit

Permalink
fix: replace deprecated set-output method
Browse files Browse the repository at this point in the history
  • Loading branch information
Ahmad Nassri committed Dec 18, 2022
1 parent 36c202e commit 8e9902c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/index.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ fi
CHANGED="$(git diff --exit-code --quiet "${BASE_SHA}" HEAD -- "${DIFF_PATHS}" && echo 'false' || echo 'true')"
FILES="$(git diff --name-only "${BASE_SHA}" HEAD -- "${DIFF_PATHS}" | tr '\n' ' ')"

echo "::set-output name=changed::${CHANGED}"
echo "changed=${CHANGED}" >> "${GITHUB_OUTPUT}"

if [[ $FILES ]]; then
echo "::set-output name=files::${FILES}"
echo "::set-output name=json::$(jq --compact-output --null-input '$ARGS.positional' --args -- "${FILES}")"
echo "files=${FILES}" >> "${GITHUB_OUTPUT}"
echo "json=$(jq --compact-output --null-input '$ARGS.positional' --args -- "${FILES}")" >> "${GITHUB_OUTPUT}"
else
echo "::set-output name=json::[]"
echo "json=[]" >> "${GITHUB_OUTPUT}"
fi

0 comments on commit 8e9902c

Please sign in to comment.