-
-
Notifications
You must be signed in to change notification settings - Fork 114
60 lines (51 loc) · 1.64 KB
/
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
name: Publish Jellyfin-Kodi
on:
workflow_dispatch:
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Update Draft
uses: release-drafter/[email protected]
with:
publish: true
env:
GITHUB_TOKEN: ${{ secrets.JF_BOT_TOKEN }}
- name: Checkout repository
uses: actions/[email protected]
- name: Set up Python
uses: actions/[email protected]
with:
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install pyyaml
- name: Build addon
run: python build.py
- name: Publish Build Artifact
uses: actions/[email protected]
with:
retention-days: 14
name: py3-build-artifact
path: |
*.zip
- name: Upload to repo server
uses: burnett01/[email protected]
with:
switches: -vrptz
path: '*.zip'
remote_path: /srv/incoming/kodi
remote_host: ${{ secrets.REPO_HOST }}
remote_user: ${{ secrets.REPO_USER }}
remote_key: ${{ secrets.REPO_KEY }}
- name: Add to Kodi repo and clean up
uses: appleboy/[email protected]
with:
host: ${{ secrets.REPO_HOST }}
username: ${{ secrets.REPO_USER }}
key: ${{ secrets.REPO_KEY }}
script_stop: true
script: |
sudo /usr/local/bin/kodirepo add /srv/incoming/kodi/plugin.video.jellyfin+py3.zip --datadir /srv/repository/main/client/kodi/py3
rm /srv/incoming/kodi/plugin.video.jellyfin+py3.zip