mirror of
https://github.com/xweiba/location-spoofer.git
synced 2026-09-25 08:01:55 +08:00
fix(update): 按语言加载三语更新日志并重发 v1.0.8
This commit is contained in:
@@ -40,16 +40,26 @@ jobs:
|
||||
- name: Validate archived release notes
|
||||
run: |
|
||||
VERSION="${{ github.ref_name }}"
|
||||
NOTES_FILE="docs/releases/${VERSION}.md"
|
||||
if [ ! -s "$NOTES_FILE" ]; then
|
||||
echo "::error::缺少版本归档 $NOTES_FILE。请在打 tag 前运行 ./Scripts/generate-release-notes.sh $VERSION 并提交。"
|
||||
exit 1
|
||||
fi
|
||||
if ! grep -Fq "# ${VERSION}" "$NOTES_FILE"; then
|
||||
echo "::error::$NOTES_FILE 的标题必须包含 # ${VERSION}"
|
||||
exit 1
|
||||
fi
|
||||
cp "$NOTES_FILE" /tmp/release_notes.md
|
||||
for NOTES_FILE in \
|
||||
"docs/releases/${VERSION}.en.md" \
|
||||
"docs/releases/${VERSION}.md" \
|
||||
"docs/releases/${VERSION}.zh-Hant.md"; do
|
||||
if [ ! -s "$NOTES_FILE" ]; then
|
||||
echo "::error::Missing localized release notes: $NOTES_FILE"
|
||||
exit 1
|
||||
fi
|
||||
if ! grep -Fq "# ${VERSION}" "$NOTES_FILE"; then
|
||||
echo "::error::$NOTES_FILE must contain the # ${VERSION} heading"
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
{
|
||||
cat "docs/releases/${VERSION}.en.md"
|
||||
printf '\n---\n\n'
|
||||
cat "docs/releases/${VERSION}.md"
|
||||
printf '\n---\n\n'
|
||||
cat "docs/releases/${VERSION}.zh-Hant.md"
|
||||
} > /tmp/release_notes.md
|
||||
|
||||
- name: Create Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
|
||||
Reference in New Issue
Block a user