2021-06-01 19:26:59 +00:00
|
|
|
name: Publish Jellyfin-Kodi
|
2021-05-14 15:18:54 +00:00
|
|
|
|
|
|
|
on:
|
2021-06-01 19:26:59 +00:00
|
|
|
workflow_dispatch:
|
2021-05-14 15:18:54 +00:00
|
|
|
|
|
|
|
jobs:
|
2021-06-01 19:26:59 +00:00
|
|
|
publish:
|
2021-05-14 15:18:54 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2021-06-01 19:26:59 +00:00
|
|
|
- name: Update Draft
|
2024-02-02 08:07:10 +00:00
|
|
|
uses: release-drafter/release-drafter@v6.0.0
|
2021-06-01 19:26:59 +00:00
|
|
|
with:
|
|
|
|
publish: true
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.JF_BOT_TOKEN }}
|
|
|
|
|
2021-05-14 15:18:54 +00:00
|
|
|
- name: Checkout repository
|
2024-06-10 03:39:05 +00:00
|
|
|
uses: actions/checkout@v4.1.6
|
2021-05-14 15:18:54 +00:00
|
|
|
|
2024-02-05 17:38:01 +00:00
|
|
|
- name: Set up Python
|
2024-06-10 03:39:08 +00:00
|
|
|
uses: actions/setup-python@v5.1.0
|
2021-05-14 15:18:54 +00:00
|
|
|
with:
|
|
|
|
python-version: 3.9
|
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
python -m pip install --upgrade pip
|
|
|
|
python -m pip install pyyaml
|
|
|
|
|
2024-02-05 17:38:01 +00:00
|
|
|
- name: Build addon
|
|
|
|
run: python build.py
|
2021-05-14 15:18:54 +00:00
|
|
|
|
2021-05-23 18:17:06 +00:00
|
|
|
- name: Publish Build Artifact
|
2024-02-05 17:38:01 +00:00
|
|
|
uses: actions/upload-artifact@v3.1.3
|
2021-05-14 15:18:54 +00:00
|
|
|
with:
|
|
|
|
retention-days: 14
|
2024-02-05 17:38:01 +00:00
|
|
|
name: py3-build-artifact
|
2021-05-14 15:18:54 +00:00
|
|
|
path: |
|
2021-05-23 18:17:06 +00:00
|
|
|
*.zip
|
2021-05-14 15:18:54 +00:00
|
|
|
|
|
|
|
- name: Upload to repo server
|
2024-02-05 17:38:01 +00:00
|
|
|
uses: burnett01/rsync-deployments@6.0.0
|
2021-05-14 15:18:54 +00:00
|
|
|
with:
|
2021-05-27 21:33:54 +00:00
|
|
|
switches: -vrptz
|
|
|
|
path: '*.zip'
|
2024-03-09 17:36:01 +00:00
|
|
|
remote_path: /srv/incoming/kodi
|
|
|
|
remote_host: ${{ secrets.REPO_HOST }}
|
|
|
|
remote_user: ${{ secrets.REPO_USER }}
|
|
|
|
remote_key: ${{ secrets.REPO_KEY }}
|
2021-05-14 15:18:54 +00:00
|
|
|
|
|
|
|
- name: Add to Kodi repo and clean up
|
2024-01-07 12:32:25 +00:00
|
|
|
uses: appleboy/ssh-action@v1.0.3
|
2021-05-14 15:18:54 +00:00
|
|
|
with:
|
2024-03-09 17:36:01 +00:00
|
|
|
host: ${{ secrets.REPO_HOST }}
|
|
|
|
username: ${{ secrets.REPO_USER }}
|
|
|
|
key: ${{ secrets.REPO_KEY }}
|
2021-05-14 15:18:54 +00:00
|
|
|
script_stop: true
|
|
|
|
script: |
|
2024-03-25 00:18:47 +00:00
|
|
|
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
|