-
-
Notifications
You must be signed in to change notification settings - Fork 28
67 lines (58 loc) · 2.21 KB
/
_meta-publish.yaml
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
on:
workflow_call:
inputs:
jellyfin_version:
required: true
type: string
server_url:
required: true
type: string
jobs:
publish:
runs-on: windows-latest
env:
DOTNET_CLI_TELEMETRY_OPTOUT: 1
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Clone UX Repository
uses: actions/checkout@v4
with:
repository: jellyfin/jellyfin-ux
path: .\jellyfin-ux
- name: Setup Jellyfin server
run: |
Invoke-WebRequest '${{ inputs.server_url }}' -OutFile 'jellyfin.zip'
Expand-Archive 'jellyfin.zip'
Copy-Item ".\Support Files\LICENSE" -Destination $(Resolve-Path .\jellyfin\jellyfin)
- name: Add NSSM
run: |
Invoke-WebRequest 'https://repo.jellyfin.org/files/other/nssm.zip' -OutFile 'nssm.zip'
Expand-Archive 'nssm.zip'
Copy-Item ".\nssm\nssm.exe" -Destination $(Resolve-Path .\jellyfin\jellyfin)
- name: Publish Tray
run: |
New-Item -Path .\jellyfin\jellyfin\jellyfin-windows-tray -ItemType Directory
dotnet publish -c Release -r win-x64 -f net472 --no-self-contained --output $(Resolve-Path .\jellyfin\jellyfin\jellyfin-windows-tray)
- name: Build installer
run: |
$env:InstallLocation = $(Resolve-Path .\jellyfin\jellyfin)
makensis /Dx64 /DUXPATH=$(Resolve-Path .\jellyfin-ux) $(Join-Path -Path $(Resolve-Path .\nsis) -ChildPath jellyfin.nsi)
- name: Rename Installer
run: |
cd .\nsis
Rename-Item -Path .\jellyfin_*_windows-x64.exe -NewName ("jellyfin_${{ inputs.jellyfin_version }}_windows-x64.exe")
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: windows-x64
retention-days: 30
if-no-files-found: error
path: .\nsis\jellyfin_*_windows-x64.exe
- name: Upload to GitHub Release
if: ${{ github.event_name == 'release' }}
uses: shogo82148/actions-upload-release-asset@v1.7.5
with:
upload_url: ${{ github.event.release.upload_url }}
overwrite: true
asset_path: .\nsis\jellyfin_*_windows-x64.exe