forked from pierr3/vSMR
-
Notifications
You must be signed in to change notification settings - Fork 4
56 lines (45 loc) · 1.6 KB
/
Copy pathbuild.yml
File metadata and controls
56 lines (45 loc) · 1.6 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
name: Build DLL
on:
pull_request:
branches: [main,master,dev,develop]
release:
types: [published]
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup MSBuild Path
uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce
- name: Bootstrap vcpkg
run: |
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg
git checkout bdd229e13c66fa11acdc0bc8fed8e7474cd24aa5
.\bootstrap-vcpkg.bat
- name: Install libcurl
run: |
.\vcpkg\vcpkg.exe install curl[core,ssl] --triplet x86-windows-static
- name: Integrate vcpkg with MSBuild
run: |
.\vcpkg\vcpkg.exe integrate install
- name: Update Plugin Version
if: github.ref_type == 'tag'
run: |
$tag = $env:GITHUB_REF -replace 'refs/tags/', ''
(Get-Content -Path "vSMR\SMRPlugin.hpp") -replace '#define MY_PLUGIN_VERSION.*', "#define MY_PLUGIN_VERSION `"$tag`"" | Set-Content -Path "vSMR\SMRPlugin.hpp"
shell: pwsh
- name: Build DLL
run: msbuild vSMR.sln /p:Configuration=Release /p:Platform='Win32' /p:VcpkgTriplet=x86-windows-static /m
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: vSMR.dll
path: Release/vSMR.dll
- name: Upload to Release
uses: softprops/action-gh-release@72f2c25fcb47643c292f7107632f7a47c1df5cd8
if: github.ref_type == 'tag'
with:
files: |
Release/vSMR.dll