-
-
Notifications
You must be signed in to change notification settings - Fork 260
61 lines (51 loc) · 1.62 KB
/
Copy pathbuild.yml
File metadata and controls
61 lines (51 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Author: Kang Lin<kl222@126.com>
# workflow syntax: https://docs.github.com/actions/writing-workflows/workflow-syntax-for-github-actions
name: build
env:
artifact_path: artifact_path
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RabbitIM_VERSION: 0.1.0
RabbitIM_VERSION_PRE: 0.1.0
on:
push:
pull_request:
jobs:
msvc:
uses: ./.github/workflows/msvc.yml
secrets: inherit
mingw:
uses: ./.github/workflows/mingw.yml
secrets: inherit
deploy:
if: ${{ startsWith(github.ref, 'refs/tags/') }}
runs-on: ubuntu-latest
needs: [mingw, msvc]
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
submodules: true
- name: Download msvc
uses: actions/download-artifact@v3
with:
name: ${{ needs.msvc.outputs.name }}
path: ${{ env.artifact_path }}
- name: Download mingw
uses: actions/download-artifact@v3
with:
name: ${{ needs.mingw.outputs.name }}
path: ${{ env.artifact_path }}
- name: Make note file
run: |
echo "[:cn: 修改日志](ChangeLog_zh_CN.md) [:us: Change log](ChangeLog.md)" > NoteFile
echo "" >> NoteFile
echo "File checksum:" >> NoteFile
cd ${{ env.artifact_path }}
for file in *
do
md5sum $file >> ../NoteFile
done
- name: Upload To Github Release
run: |
gh release create ${{ github.ref_name }} --title ${{ github.ref_name }} --notes-file NoteFile
gh release upload ${{ github.ref_name }} ${{github.workspace}}/${{ env.artifact_path }}/*