-
Notifications
You must be signed in to change notification settings - Fork 39
134 lines (131 loc) · 3.61 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
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
126
127
128
129
130
131
132
133
134
name: Windows Build
on: [push, pull_request]
concurrency:
group: ci-${{github.actor}}-${{github.head_ref || github.run_number}}-${{github.ref}}-windows
cancel-in-progress: true
jobs:
windows-vs:
name: win-vs 🏁
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
lib-type:
- static
- shared
graphics-api:
- DX11
- OpenGL
env:
HOST: ${{ github.job }}
PLATFORM: win-vs
LIB_TYPE: ${{ matrix.lib-type }}
GRAPHICS_API: ${{ matrix.graphics-api }}
URHO3D_DOCS: 0
steps:
- name: Checkout
uses: actions/checkout@v4
with: { fetch-depth: 0 }
- name: Set cache TTL
run: |
echo ("CACHE_MONTH=vs_" + $(date '+%b %Y')) >> $env:GITHUB_ENV
- name: CMake
run: rake cmake
- name: Build
run: rake build
- name: Test
run: rake test
if: matrix.graphics-api != 'OpenGL'
- name: Install
run: rake install
- name: Scaffolding - new
run: rake new
- name: Scaffolding - build
run: |
cd ~/projects/UrhoApp
rake
- name: Scaffolding - test
run: |
cd ~/projects/UrhoApp
rake test
if: matrix.graphics-api != 'OpenGL'
- name: Scaffolding - cleanup
run: rm -r -fo ~/.urho3d, ~/Projects
- name: Package
run: rake package
if: github.event_name == 'push'
- name: Upload
uses: actions/upload-artifact@v4
with:
name: win-vs-${{ matrix.lib-type }}-64-${{ matrix.graphics-api }}-rel
path: build/ci/*.zip
if: github.event_name == 'push'
windows-gcc:
name: win-gcc 🏁
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
lib-type:
- static
- shared
graphics-api:
- DX11
- OpenGL
env:
HOST: ${{ github.job }}
PLATFORM: win-gcc
LIB_TYPE: ${{ matrix.lib-type }}
GRAPHICS_API: ${{ matrix.graphics-api }}
URHO3D_DOCS: 0
MINGW_SYSROOT: 'C:/ProgramData/chocolatey/lib/mingw'
steps:
- name: Checkout
uses: actions/checkout@v4
with: { fetch-depth: 0 }
- name: Set cache TTL
run: |
echo ("CACHE_MONTH=gcc_" + $(date '+%b %Y')) >> $env:GITHUB_ENV
- name: Cache MinGW installation
id: cache-mingw
uses: actions/cache@v4
with:
path: C:\ProgramData\chocolatey\lib\mingw
key: ${{ env.CACHE_MONTH }}
- name: Set up MinGW
uses: egor-tensin/setup-mingw@v2.2.0
with:
version: 12.2.0
platform: x64
if: steps.cache-mingw.outputs.cache-hit != 'true'
- name: CMake
run: rake cmake
- name: Build
run: rake build
- name: Test
run: rake test
if: matrix.graphics-api != 'OpenGL'
- name: Install
run: rake install
- name: Scaffolding - new
run: rake new
- name: Scaffolding - build
run: |
cd ~/projects/UrhoApp
rake
- name: Scaffolding - test
run: |
cd ~/projects/UrhoApp
rake test
if: matrix.graphics-api != 'OpenGL'
- name: Scaffolding - cleanup
run: rm -r -fo ~/.urho3d, ~/Projects
- name: Package
run: rake package
if: github.event_name == 'push'
- name: Upload
uses: actions/upload-artifact@v4
with:
name: win-gcc-${{ matrix.lib-type }}-64-${{ matrix.graphics-api }}-rel
path: build/ci/*.zip
if: github.event_name == 'push'