Skip to content

Commit b4eeedf

Browse files
fix
1 parent 2505757 commit b4eeedf

1 file changed

Lines changed: 14 additions & 55 deletions

File tree

.github/workflows/install.yml

Lines changed: 14 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -236,9 +236,9 @@ jobs:
236236
name: MaaNTE-win-${{ matrix.arch }}-${{ needs.meta.outputs.tag }}-MXU
237237
path: "install-mxu"
238238

239-
changelog:
240-
name: Generate changelog
241-
needs: meta
239+
release:
240+
if: ${{ needs.meta.outputs.is_release == 'true' }}
241+
needs: [meta, windows]
242242
runs-on: ubuntu-latest
243243
steps:
244244
- name: Checkout
@@ -260,56 +260,6 @@ jobs:
260260
OUTPUT: CHANGES.md
261261
GITHUB_REPO: ${{ github.repository }}
262262

263-
- name: Build release note file
264-
shell: bash
265-
env:
266-
RELEASE_BODY: ${{ steps.git-cliff.outputs.content }}
267-
run: |
268-
printf '%s\n\n' "$RELEASE_BODY" > release-note.md
269-
echo '[已有 Mirror酱 CDK?前往 Mirror酱 高速下载](https://mirrorchyan.com/zh/projects?rid=MaaNTE)' >> release-note.md
270-
echo '[夸克网盘](https://pan.quark.cn/s/9eb393a6c95e?pwd=8nuf)' >> release-note.md
271-
echo '[百度网盘](https://pan.baidu.com/s/11QMC-aYfjfq52yco_UAwfg?pwd=tkmu)' >> release-note.md
272-
273-
- name: Print release note preview
274-
if: ${{ needs.meta.outputs.is_release != 'true' }}
275-
shell: bash
276-
run: |
277-
echo '===== Release note preview ====='
278-
cat release-note.md
279-
echo '===== End release note preview ====='
280-
281-
release:
282-
if: ${{ needs.meta.outputs.is_release == 'true' }}
283-
needs: [meta, windows, changelog]
284-
runs-on: ubuntu-latest
285-
steps:
286-
- name: Checkout
287-
uses: actions/checkout@v4
288-
with:
289-
fetch-depth: 0
290-
291-
- name: Generate a changelog
292-
uses: orhun/git-cliff-action@v4
293-
id: git-cliff-release
294-
with:
295-
config: .github/cliff.toml
296-
args: >-
297-
-vv --latest --strip header
298-
${{ needs.meta.outputs.is_prerelease == 'false' && '--tag-pattern "^v[0-9]+\\.[0-9]+\\.[0-9]+$"' || '' }}
299-
env:
300-
OUTPUT: CHANGES.md
301-
GITHUB_REPO: ${{ github.repository }}
302-
303-
- name: Build release note file
304-
shell: bash
305-
env:
306-
RELEASE_BODY: ${{ steps.git-cliff-release.outputs.content }}
307-
run: |
308-
printf '%s\n\n' "$RELEASE_BODY" > release-note.md
309-
echo '[已有 Mirror酱 CDK?前往 Mirror酱 高速下载](https://mirrorchyan.com/zh/projects?rid=MaaNTE)' >> release-note.md
310-
echo '[夸克网盘](https://pan.quark.cn/s/9eb393a6c95e?pwd=8nuf)' >> release-note.md
311-
echo '[百度网盘](https://pan.baidu.com/s/11QMC-aYfjfq52yco_UAwfg?pwd=tkmu)' >> release-note.md
312-
313263
- uses: actions/download-artifact@v4
314264
with:
315265
pattern: MaaNTE-*
@@ -356,13 +306,22 @@ jobs:
356306
fi
357307
done
358308
359-
- uses: softprops/action-gh-release@v2.2.2
309+
- name: Release
310+
uses: softprops/action-gh-release@v3
311+
env:
312+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
360313
with:
361314
files: assets/*
362315
tag_name: ${{ needs.meta.outputs.tag }}
363-
body_path: release-note.md
316+
body: |
317+
${{ steps.git-cliff.outputs.content }}
318+
319+
[已有 Mirror酱 CDK?前往 Mirror酱 高速下载](https://mirrorchyan.com/zh/projects?rid=MaaNTE)
320+
[夸克网盘](https://pan.quark.cn/s/9eb393a6c95e?pwd=8nuf)
321+
[百度网盘](https://pan.baidu.com/s/11QMC-aYfjfq52yco_UAwfg?pwd=tkmu)
364322
draft: false
365323
prerelease: ${{ needs.meta.outputs.is_prerelease == 'true' }}
324+
make_latest: ${{ needs.meta.outputs.is_prerelease == 'false' }}
366325

367326
- name: Trigger MirrorChyanUploading
368327
shell: bash

0 commit comments

Comments
 (0)