forked from Exiled-Official/EXILED
-
Notifications
You must be signed in to change notification settings - Fork 49
76 lines (59 loc) · 2.09 KB
/
dev.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
name: Exiled Dev CI
on:
push:
branches:
- dev
- scpsl14
pull_request:
branches:
- dev
- scpsl14
workflow_dispatch:
defaults:
run:
working-directory: ./EXILED
env:
EXILED_REFERENCES_URL: https://exmod-team.github.io/SL-References/Dev.zip
EXILED_REFERENCES_PATH: ${{ github.workspace }}/EXILED/References
EXILED_DLL_ARCHIVER_URL: https://github.com/ExMod-Team/EXILED-DLL-Archiver/releases/latest/download/EXILED-DLL-Archiver.exe
jobs:
build:
runs-on: windows-latest
# Prevent double running for push & pull_request events from the main repo
if: github.event_name != 'push' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
steps:
- name: Setup .NET Core SDK
uses: actions/setup-dotnet@v4.0.1
- name: Setup Nuget
uses: nuget/setup-nuget@v2
- uses: actions/checkout@v4.1.7
- name: Get references
shell: pwsh
run: |
Invoke-WebRequest -Uri ${{ env.EXILED_REFERENCES_URL }} -OutFile ${{ github.workspace }}/EXILED/References.zip
Expand-Archive -Path References.zip -DestinationPath ${{ env.EXILED_REFERENCES_PATH }}
- name: Build
env:
EXILED_REFERENCES: ${{ env.EXILED_REFERENCES_PATH }}
shell: pwsh
run: |
./build.ps1 -BuildNuGet
$File = (Get-ChildItem -Path . -Include 'ExMod.Exiled.*.nupkg' -Recurse).Name
Out-File -FilePath ${{ github.env }} -InputObject "PackageFile=$File" -Encoding utf-8 -Append
- name: Upload nuget package
uses: actions/upload-artifact@v4
with:
name: ${{ env.PackageFile }}
path: EXILED/${{ env.PackageFile }}
- name: Get references
shell: pwsh
run: |
Invoke-WebRequest -Uri ${{ env.EXILED_DLL_ARCHIVER_URL }} -OutFile ${{ github.workspace }}/EXILED/EXILED-DLL-Archiver.exe
- name: Packaging results as tar.gz
shell: pwsh
run: ./packaging.ps1
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: Build Result
path: EXILED/bin/Release/Exiled.tar.gz