Skip to content

Commit

Permalink
fix(actions/flux-localhost-build): use file reference for commit content
Browse files Browse the repository at this point in the history
argument list too long
  • Loading branch information
JJGadgets committed May 19, 2024
1 parent a1a473b commit e2d0ab2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/flux-localhost-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,17 +81,17 @@ jobs:
run: |
export MESSAGE="${{ env.MESSAGE }}"
export SHA=$( git rev-parse ${{ env.DESTINATION_BRANCH }}:${{ env.FILE_TO_COMMIT }} )
export CONTENT=$( base64 -i ${{ env.FILE_TO_COMMIT }} )
base64 -i -w0 ${{ env.FILE_TO_COMMIT }} > /tmp/base64data
if gh api --method PUT /repos/:owner/:repo/contents/${{ env.FILE_TO_COMMIT }} \
--field message="${MESSAGE}" \
--field content="${CONTENT}" \
--field content="@/tmp/base64data" \
--field encoding="base64" \
--field branch="${{ env.DESTINATION_BRANCH }}" \
--field sha="${SHA}" ; then
echo "Pushed signed commit to GitHub."
elif gh api --method PUT /repos/:owner/:repo/contents/${{ env.FILE_TO_COMMIT }} \
--field message="${MESSAGE}" \
--field content="${CONTENT}" \
--field content="@/tmp/base64data" \
--field encoding="base64" \
--field branch="${{ env.DESTINATION_BRANCH }}" ; then
echo "Pushed signed commit to GitHub."
Expand Down

0 comments on commit e2d0ab2

Please sign in to comment.