Skip to content
Closed
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 19 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@
file bin/*

- name: Create Release
run: |

Check warning on line 179 in .github/workflows/release.yml

View workflow job for this annotation

GitHub Actions / Lint

[actionlint] reported by reviewdog 🐶 shellcheck reported issue in this script: SC2086:info:15:33: Double quote to prevent globbing and word splitting [shellcheck] Raw Output: i:.github/workflows/release.yml:179:9: shellcheck reported issue in this script: SC2086:info:15:33: Double quote to prevent globbing and word splitting [shellcheck]
if [[ "${PRE_RELEASE_INPUT}" == "false" ]]; then
RELEASE_TYPE_NAME=Release
PRERELEASE_ARG=
Expand All @@ -184,16 +184,27 @@
RELEASE_TYPE_NAME=Pre-Release
PRERELEASE_ARG=--prerelease
fi

today=$(date '+%Y-%m-%d')

# Generate a concise changelog (last 50 commits) to stay under the 125k character limit
echo "## What's Changed" > /tmp/release_notes.md
PREV_TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "")
if [ -n "$PREV_TAG" ]; then
git log --oneline --no-merges ${PREV_TAG}..HEAD | head -n 50 >> /tmp/release_notes.md
else
git log --oneline --no-merges | head -n 50 >> /tmp/release_notes.md
fi
echo "" >> /tmp/release_notes.md
echo "**Full Changelog**: https://github.com/${GITHUB_REPOSITORY}/compare/${PREV_TAG}...${tag}" >> /tmp/release_notes.md
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved

gh release create "$today-$tag-$run" \
--repo="$GITHUB_REPOSITORY" \
--title="RustPython $RELEASE_TYPE_NAME $today-$tag #$run" \
--target="$tag" \
--notes "⚠️ **Important**: To run RustPython, you must download both the binary for your platform AND the \`rustpython-lib.zip\` archive. Extract the Lib directory from the archive to the same location as the binary, or set the \`RUSTPYTHONPATH\` environment variable to point to the Lib directory." \
--generate-notes \
$PRERELEASE_ARG \
bin/rustpython-release-*
--repo="$GITHUB_REPOSITORY" \
--title="RustPython $RELEASE_TYPE_NAME $today-$tag #$run" \
--target="$tag" \
--notes-file /tmp/release_notes.md \
"$PRERELEASE_ARG" \
bin/rustpython-release-*
env:
GH_TOKEN: ${{ github.token }}
tag: ${{ github.ref_name }}
Expand Down
Loading