-
Notifications
You must be signed in to change notification settings - Fork 29
54 lines (42 loc) · 1.48 KB
/
build.yaml
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
name: Build
on: [push]
env:
is_tag: ${{ startsWith(github.ref, 'refs/tags/') }}
PROJECT_FILE_PATH: blur.sln
BUILD_CONFIGURATION: Release
BUILD_PLATFORM: x64
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- name: Add MSBuild to PATH
uses: microsoft/[email protected]
- name: Setup vcpkg
uses: lukka/run-vcpkg@v7
with:
vcpkgDirectory: ${{ runner.workspace }}/vcpkg/
vcpkgTriplet: '${{ env.BUILD_PLATFORM }}-windows-static'
vcpkgGitCommitId: '8eb57355a4ffb410a2e94c07b4dca2dffbee8e50'
vcpkgArguments: 'cxxopts fmt glfw3 imgui[opengl3-binding,glfw-binding] nlohmann-json'
- name: Integrate vcpkg
run: ${{ runner.workspace }}\vcpkg\vcpkg integrate install
- name: Build
working-directory: ${{ env.GITHUB_WORKSPACE }}
run: MSBuild /p:Configuration=${{ env.BUILD_CONFIGURATION }} /p:Platform=${{ env.BUILD_PLATFORM }} ${{ env.PROJECT_FILE_PATH }}
- name: Upload
uses: actions/upload-artifact@v3
with:
name: Blur
path: |
bin/blur-cli/Release/blur-cli.exe
bin/blur-gui/Release/blur.exe
- name: Release
uses: softprops/action-gh-release@v1
if: ${{ env.is_tag == 'true' }}
with:
files: |
bin/blur-cli/Release/blur-cli.exe
bin/blur-gui/Release/blur.exe
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}