Use fully qualified version numbers for CI

🧹 Clean up CI after removing py2
This commit is contained in:
Odd Stråbø 2024-02-05 17:38:01 +00:00
parent f1cd38a530
commit bdebed0cf8
5 changed files with 29 additions and 39 deletions

View file

@ -10,15 +10,12 @@ on:
jobs: jobs:
build: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy:
matrix:
py_version: [ 'py3' ]
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4.1.1
- name: Set up Python 3.x - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5.0.0
with: with:
python-version: 3.9 python-version: 3.9
@ -27,13 +24,13 @@ jobs:
python -m pip install --upgrade pip python -m pip install --upgrade pip
python -m pip install pyyaml python -m pip install pyyaml
- name: Create ${{ matrix.py_version }} addon.xml - name: Build addon
run: python build.py --version ${{ matrix.py_version }} run: python build.py
- name: Publish Build Artifact - name: Publish Build Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3.1.3
with: with:
retention-days: 14 retention-days: 14
name: ${{ matrix.py_version }}-build-artifact name: py3-build-artifact
path: | path: |
*.zip *.zip

View file

@ -16,26 +16,23 @@ jobs:
if: ${{ github.repository == 'jellyfin/jellyfin-kodi' }} if: ${{ github.repository == 'jellyfin/jellyfin-kodi' }}
strategy: strategy:
fail-fast: false fail-fast: false
matrix:
language: [ 'python' ]
version: ['3.9']
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4.1.1
- name: Initialize CodeQL - name: Initialize CodeQL
uses: github/codeql-action/init@v3 uses: github/codeql-action/init@v3.24.0
with: with:
languages: ${{ matrix.language }} languages: 'python'
queries: +security-and-quality queries: +security-and-quality
- name: Set up Python ${{ matrix.version }} - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5.0.0
with: with:
python-version: ${{ matrix.version }} python-version: 3.9
- name: Autobuild - name: Autobuild
uses: github/codeql-action/autobuild@v3 uses: github/codeql-action/autobuild@v3.24.0
- name: Perform CodeQL Analysis - name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3 uses: github/codeql-action/analyze@v3.24.0

View file

@ -21,7 +21,7 @@ jobs:
yq-version: v4.9.1 yq-version: v4.9.1
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4.1.1
- name: Parse Changelog - name: Parse Changelog
run: | run: |

View file

@ -6,23 +6,19 @@ on:
jobs: jobs:
publish: publish:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy:
matrix:
py_version: [ 'py3' ]
steps: steps:
- name: Update Draft - name: Update Draft
uses: release-drafter/release-drafter@v6.0.0 uses: release-drafter/release-drafter@v6.0.0
if: ${{ matrix.py_version == 'py3' }}
with: with:
publish: true publish: true
env: env:
GITHUB_TOKEN: ${{ secrets.JF_BOT_TOKEN }} GITHUB_TOKEN: ${{ secrets.JF_BOT_TOKEN }}
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4.1.1
- name: Set up Python 3.x - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5.0.0
with: with:
python-version: 3.9 python-version: 3.9
@ -31,19 +27,19 @@ jobs:
python -m pip install --upgrade pip python -m pip install --upgrade pip
python -m pip install pyyaml python -m pip install pyyaml
- name: Create ${{ matrix.py_version }} addon.xml - name: Build addon
run: python build.py --version ${{ matrix.py_version }} run: python build.py
- name: Publish Build Artifact - name: Publish Build Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3.1.3
with: with:
retention-days: 14 retention-days: 14
name: ${{ matrix.py_version }}-build-artifact name: py3-build-artifact
path: | path: |
*.zip *.zip
- name: Upload to repo server - name: Upload to repo server
uses: burnett01/rsync-deployments@5.2 uses: burnett01/rsync-deployments@6.0.0
with: with:
switches: -vrptz switches: -vrptz
path: '*.zip' path: '*.zip'
@ -60,5 +56,5 @@ jobs:
key: ${{ secrets.DEPLOY_KEY }} key: ${{ secrets.DEPLOY_KEY }}
script_stop: true script_stop: true
script: | script: |
python3 /usr/local/bin/kodirepo add /srv/repository/incoming/kodi/plugin.video.jellyfin+${{ matrix.py_version }}.zip --datadir /srv/repository/releases/client/kodi/${{ matrix.py_version }}; python3 /usr/local/bin/kodirepo add /srv/repository/incoming/kodi/plugin.video.jellyfin+py3.zip --datadir /srv/repository/releases/client/kodi/py3;
rm /srv/repository/incoming/kodi/plugin.video.jellyfin+${{ matrix.py_version }}.zip; rm /srv/repository/incoming/kodi/plugin.video.jellyfin+py3.zip;

View file

@ -22,10 +22,10 @@ jobs:
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4.1.1
- name: Set up Python ${{ matrix.py_version }} - name: Set up Python ${{ matrix.py_version }}
uses: actions/setup-python@v5 uses: actions/setup-python@v5.0.0
with: with:
python-version: ${{ matrix.py_version }} python-version: ${{ matrix.py_version }}
@ -56,7 +56,7 @@ jobs:
if: ${{ matrix.py_version == '3.11' }} if: ${{ matrix.py_version == '3.11' }}
- name: Publish Test Artifact - name: Publish Test Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3.1.3
with: with:
retention-days: 14 retention-days: 14
name: ${{ matrix.py_version }}-test-results name: ${{ matrix.py_version }}-test-results