-
Notifications
You must be signed in to change notification settings - Fork 2
51 lines (51 loc) · 1.35 KB
/
build.yml
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
name: Multi-platform Build
on:
push:
branches:
- master
- action-test
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest]
build_type: [Debug, Release]
steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Build
run: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DUSE_STATIC=ON ..
cmake --build . --config ${{ matrix.build_type }}
- name: Publish Artifacts
if: ${{ matrix.os }} == "windows-latest"
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}-${{ matrix.build_type }}
path: |
build/${{ matrix.build_type }}/rtc.*
release:
needs: build
runs-on: ubuntu-latest
steps:
- name: Restore All Artifacts
uses: actions/download-artifact@v3
with:
path: artifacts
- name: Get current date
id: date
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT
- name: Publish Release
id: rtc_release
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: 'latest'
name: latest-${{ steps.date.outputs.date }}
draft: false
prerelease: false
files: artifacts/**/*