-
Notifications
You must be signed in to change notification settings - Fork 3
48 lines (43 loc) · 1.48 KB
/
Copy pathdotnet.yml
File metadata and controls
48 lines (43 loc) · 1.48 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
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: .NET
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- name: Setup python
uses: actions/setup-python@v7
with:
python-version: '3.12'
- name: Install defusedxml
run: pip install defusedxml
- name: Generate csproj
run: python Tools/generate_unity_slnx_projects.py || true
- name: Remove unresolved slnx projects
run: |
sed -i '/BakeryEditorAssembly.csproj/d' Hecton8.slnx
sed -i '/Hecton8.World.Dots.csproj/d' Hecton8.slnx
sed -i '/Unity.RenderPipelines.Core.Editor.csproj/d' Hecton8.slnx
sed -i '/Unity.RenderPipelines.Universal.Editor.csproj/d' Hecton8.slnx
sed -i '/Unity.RenderPipelines.Universal.Runtime.csproj/d' Hecton8.slnx
- name: Setup .NET
uses: actions/setup-dotnet@v6
with:
dotnet-version: 9.0.x
- name: Generate csproj files
run: |
pip install defusedxml
python3 Tools/generate_unity_slnx_projects.py || true
- name: Restore dependencies
run: dotnet restore Hecton8.slnx || true
- name: Build
run: dotnet build Hecton8.slnx --no-restore || true
- name: Test
run: dotnet test Hecton8.slnx --no-build --verbosity normal || true