Update read file action in bounty workflow

The read file action in the bounty workflow has been updated, replacing the previous manual method with a more efficient GitHub action. This action greatly simplifies the code, improving readability and ease of maintenance. The file path has also been corrected.
This commit is contained in:
Sipke Schoorstra 2024-04-10 19:47:18 +02:00
parent 1db8cc91f6
commit 593edd54a9

View file

@ -14,16 +14,16 @@ jobs:
- name: Read Footer Content
id: footer
run: |
content=$(cat .github/bounty-footer.md | jq -Rs .)
echo "::set-output name=content::$content"
uses: jaywcjlove/github-action-read-file@main
with:
path: docs/bounty-footer.md
- name: Append Footer to Issue
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const issueComment = `${{ steps.footer.outputs.content }}`;
const issueComment = "${{ steps.footer.outputs.content }}";
await github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,