mirror of
https://code.forgejo.org/actions/forgejo-release.git
synced 2025-11-28 02:01:58 +02:00
feat: release notes from file
Takes priority over `release-notes`. Most useful in cases where we need to generate something from a script; for example, if you have like 80 different assets and autogenerate a table to make it easier for users to select their platform/sums/etc Signed-off-by: crueter <crueter@eden-emu.dev>
This commit is contained in:
parent
e5e095057a
commit
05d41bd915
2 changed files with 35 additions and 0 deletions
13
action.yml
13
action.yml
|
|
@ -26,6 +26,9 @@ inputs:
|
|||
required: true
|
||||
release-notes:
|
||||
description: 'Release notes'
|
||||
release-notes-file:
|
||||
description: 'Path to a file containing your release notes (takes priority over release-notes)'
|
||||
required: false
|
||||
direction:
|
||||
description: 'Can either be `download` or `upload`'
|
||||
required: true
|
||||
|
|
@ -97,6 +100,16 @@ runs:
|
|||
EOF
|
||||
)
|
||||
|
||||
RELEASENOTES_FILE="${{ inputs.release-notes-file }}"
|
||||
if [ ! -z "$RELEASENOTES_FILE" ]; then
|
||||
if [ ! -f "$RELEASENOTES_FILE" ]; then
|
||||
echo "! Release notes file $RELEASENOTES_FILE does not exist."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
export RELEASENOTES=$(cat "$RELEASENOTES_FILE")
|
||||
fi
|
||||
|
||||
export SHA="${{ inputs.sha }}"
|
||||
|
||||
export OVERRIDE="${{ inputs.override }}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue