fix: use yes/no instead of true/false for using a binary built from source (#948)

and add information from steps and inputs context for future debug.

---

For debugging a temporary commit [that trims the tests is used](https://code.forgejo.org/forgejo/end-to-end/pulls/948/commits/5e6bd041158847de99908464d629cbd85d14b951)

## No build from source

- https://code.forgejo.org/forgejo/end-to-end/actions/runs/3905
   ![image](/attachments/66ef5aa0-25a8-4624-9d92-dd18dce0a427)

## Build from source

A temporary commit [is used to build from sources](https://code.forgejo.org/forgejo/end-to-end/pulls/948/commits/ffa5170ba21c070208c7934d727327efc0ec248f).

- https://code.forgejo.org/forgejo/end-to-end/actions/runs/3904
  ![image](/attachments/e335ee9f-fa07-43e0-aaf4-dfa745aa2a6a)

Reviewed-on: https://code.forgejo.org/forgejo/end-to-end/pulls/948
Co-authored-by: Earl Warren <contact@earl-warren.org>
Co-committed-by: Earl Warren <contact@earl-warren.org>
This commit is contained in:
Earl Warren 2025-08-17 08:44:56 +00:00 committed by earl-warren
parent 1e33063227
commit 95453f8fd8
No known key found for this signature in database
GPG key ID: F128CBE6AB3A7201
2 changed files with 17 additions and 4 deletions

View file

@ -19,8 +19,14 @@ runs:
with:
install-only: true
- run: forgejo-binary.sh ensure_user forgejo
- name: inputs context dump for debug
run: |
set -x
cat <<EOF
${{ toJSON(inputs) }}
EOF
- uses: actions/download-artifact@v3
if: ${{ inputs.built == true }}
if: ${{ inputs.built == 'yes' }}
with:
name: forgejo-dev
path: /srv/forgejo-binaries

View file

@ -41,7 +41,7 @@ jobs:
if ! test -f forgejo/build-from-sources; then
echo forgejo/build-from-sources is not present, do not build any version from source
echo "built=false" >> $FORGEJO_OUTPUT
echo "built=no" >> $FORGEJO_OUTPUT
exit 0
fi
@ -62,10 +62,17 @@ jobs:
mv $forgejo /tmp/forgejo-upload/forgejo-$version
done
echo "built=true" >> $FORGEJO_OUTPUT
echo "built=yes" >> $FORGEJO_OUTPUT
- name: steps context dump for debug
run: |
set -x
cat <<EOF
${{ toJSON(steps) }}
EOF
- uses: actions/upload-artifact@v3
if: ${{ steps.build.outputs.built == true }}
if: ${{ steps.build.outputs.built == 'yes' }}
with:
name: forgejo-dev
path: /tmp/forgejo-upload