-
Notifications
You must be signed in to change notification settings - Fork 10
125 lines (99 loc) · 3.88 KB
/
pull_request.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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
#
# GitHub action to build pull requests.
#
name: Pull Request
on:
pull_request:
jobs:
pr_build:
name: Pull Request
strategy:
fail-fast: false
runs-on: windows-latest
steps:
- name: Clone Repository
uses: actions/checkout@v4
- name: Checkout Files
uses: actions/checkout@v4
with:
repository: Vinifera-Developers/Vinifera-Files
path: vinifera-files
- name: Set Variables
id: vars
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- name: Install Dependencies
run: |
Invoke-WebRequest -Uri https://github.com/ninja-build/ninja/releases/download/v1.10.1/ninja-win.zip -OutFile $Env:TEMP\ninja-win.zip
Expand-Archive $Env:TEMP\ninja-win.zip -DestinationPath $Env:TEMP\ninja
echo "$Env:TEMP\ninja" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- uses: ilammy/msvc-dev-cmd@v1.10.0
with:
arch: x86
- name: Configure Project
run: |
cmake -G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo -B build -DPREVIEW=ON
- name: Build Project
run: |
cmake --build build --config RelWithDebInfo
- name: Copy Binaries
shell: bash
run: |
mkdir artifact
mkdir artifact/Movies
cp ./build/Vinifera.dll ./artifact/Vinifera.dll
cp ./build/Vinifera.pdb ./artifact/Vinifera.pdb
cp ./build/LaunchVinifera.exe ./artifact/LaunchVinifera.exe
cp ./build/_deps/tspp-src/pdb/Game.pdb ./artifact/Game.pdb
cp ./build/_deps/tspp-src/edb/Game.edb ./artifact/Game.edb
cp ./vinifera-files/files/VINIFERA.VQA ./artifact/Movies/VINIFERA.VQA
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: vinifera-preview-${{ steps.vars.outputs.sha_short }}
path: artifact
pr_build_ts_client:
name: Pull Request (TS-Client)
strategy:
fail-fast: false
runs-on: windows-latest
steps:
- name: Clone Repository
uses: actions/checkout@v4
- name: Checkout Files
uses: actions/checkout@v4
with:
repository: Vinifera-Developers/Vinifera-Files
path: vinifera-files
- name: Set Variables
id: vars
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- name: Install Dependencies
run: |
Invoke-WebRequest -Uri https://github.com/ninja-build/ninja/releases/download/v1.10.1/ninja-win.zip -OutFile $Env:TEMP\ninja-win.zip
Expand-Archive $Env:TEMP\ninja-win.zip -DestinationPath $Env:TEMP\ninja
echo "$Env:TEMP\ninja" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- uses: ilammy/msvc-dev-cmd@v1.10.0
with:
arch: x86
- name: Configure Project
run: |
cmake -G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo -B build -DPREVIEW=ON -DOPTION_TS_CLIENT_BUILD=ON
- name: Build Project
run: |
cmake --build build --config RelWithDebInfo
- name: Copy Binaries
shell: bash
run: |
mkdir artifact
mkdir artifact/Movies
cp ./build/Vinifera.dll ./artifact/Vinifera.dll
cp ./build/Vinifera.pdb ./artifact/Vinifera.pdb
cp ./build/LaunchVinifera.exe ./artifact/LaunchVinifera.dat
cp ./build/_deps/tspp-src/pdb/Game.pdb ./artifact/Game.pdb
cp ./build/_deps/tspp-src/edb/Game.edb ./artifact/Game.edb
cp ./vinifera-files/files/VINIFERA.WMV ./artifact/Movies/VINIFERA.VQA
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: vinifera-preview-${{ steps.vars.outputs.sha_short }}-ts_client
path: artifact