-
Notifications
You must be signed in to change notification settings - Fork 40
84 lines (69 loc) · 2.27 KB
/
windows.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: windows
on:
push:
tags:
- "v*"
pull_request:
tags:
- "v*"
env:
# Path to the solution file relative to the root of the project.
SOLUTION_FILE_PATH: .
# Configuration type to build.
# You can convert this to a build matrix if you need coverage of multiple configuration types.
# https://docs.github.com/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
BUILD_CONFIGURATION: Release
jobs:
build:
runs-on: windows-2022
if: github.repository == 'hzqst/MetaHookSv'
steps:
- uses: hzqst/checkout@v2.3.4
- name: Init dependencies
working-directory: ${{env.GITHUB_WORKSPACE}}
run: git submodule update --init --recursive
shell: cmd
- name: Build MetaHook
working-directory: ${{env.GITHUB_WORKSPACE}}
run: scripts\build-MetaHook.bat
shell: cmd
- name: Build Plugins
working-directory: ${{env.GITHUB_WORKSPACE}}
run: scripts\build-Plugins.bat
shell: cmd
- name: Create Output directory
working-directory: ${{env.GITHUB_WORKSPACE}}
run: mkdir Output
shell: cmd
- name: Copy Build to Output
working-directory: ${{env.GITHUB_WORKSPACE}}
run: |
mkdir "Output\Build"
xcopy "Build" "Output\Build" /y /e
shell: cmd
- name: Copy SteamAppsLocation to Output
working-directory: ${{env.GITHUB_WORKSPACE}}
run: |
mkdir "Output\tools"
copy "tools\SteamAppsLocation.exe" "Output\tools" /y
copy "tools\steam_appid.txt" "Output\tools" /y
copy "tools\steam_api.dll" "Output\tools" /y
shell: cmd
- name: Copy install bat to Output
working-directory: ${{env.GITHUB_WORKSPACE}}
run: |
mkdir "Output\scripts"
copy "scripts\install-*.bat" "Output\scripts" /y
shell: cmd
- name: Zipping All
uses: vimtor/action-zip@v1
with:
files: Output/
dest: MetaHookSv-windows-x86.zip
- name: Create Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
name: MetaHookSv-${{ github.ref }}
files: |
MetaHookSv-windows-x86.zip