mirror of
https://github.com/metatube-community/jellyfin-plugin-metatube.git
synced 2026-05-05 05:11:29 +08:00
61 lines
1.9 KiB
YAML
61 lines
1.9 KiB
YAML
name: Build Plugins
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Setup .NET Core
|
|
uses: actions/setup-dotnet@v1
|
|
with:
|
|
dotnet-version: 6.0.x
|
|
|
|
- name: Setup Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.x'
|
|
|
|
- name: Generate Version
|
|
id: shell
|
|
run: |
|
|
echo ::set-output name=version::$(date '+%Y.%m%d.%H%M')
|
|
|
|
- name: Build Plugins
|
|
run: |
|
|
dotnet build --configuration Release -p:Version=${{ steps.shell.outputs.version }}
|
|
dotnet build --configuration Release.Emby -p:Version=${{ steps.shell.outputs.version }}
|
|
|
|
- name: Generate Manifest
|
|
run: |
|
|
python3 scripts/manifest.py Jellyfin.Plugin.JavTube/bin/Jellyfin.JavTube@v${{ steps.shell.outputs.version }}.zip
|
|
|
|
- name: Publish Manifest
|
|
run: |
|
|
git config --global user.name 'github-actions[bot]'
|
|
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
|
|
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${GITHUB_REPOSITORY}
|
|
|
|
git checkout --orphan dist
|
|
git rm -rf .
|
|
git add manifest.json
|
|
git commit -m "Auto Updated by Actions"
|
|
git push -f -u origin dist
|
|
|
|
- name: Upload Plugins
|
|
uses: softprops/action-gh-release@v1
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
with:
|
|
body: Auto Released by Actions
|
|
draft: false
|
|
tag_name: v${{ steps.shell.outputs.version }}
|
|
files: |
|
|
Jellyfin.Plugin.JavTube/bin/Jellyfin.JavTube@v${{ steps.shell.outputs.version }}.zip
|
|
Jellyfin.Plugin.JavTube/bin/Emby.JavTube@v${{ steps.shell.outputs.version }}.zip
|