Skip to main content

include_toc: true gitea: none

What is it?

This is a fork of https://github.com/oddstr13/jellyfin-plugin-repository-manager mainly because I have different opinions on how things should work.

Installing

Use pipx or use a virtualenv From PyPI

pipx install traitorous-jprm

From git

pipx install git+https://gitea.narnian.us/lordwelch/traitorous-jprm

From local developement directory

git clone https://gitea.narnian.us/lordwelch/traitorous-jprm
pipx install --editable ./traitorous-jprm

Examples

Running jprm

jprm --version
python3 -m jprm --version
python3 jprm.py --version

GitHub Release

GitHub Release - Make a plugin

Fork https://github.com/jellyfin/jellyfin-plugin-template

git clone https://github.com/lordwelch/jellyfin-plugin-template
cd jellyfin-plugin-template

GitHub Release - Migrate to new sln file (optional)

dotnet sln migrate Jellyfin.Plugin.Template.sln
rm Jellyfin.Plugin.Template.sln

GitHub Release - Get a logo (optional)

curl -Lo logo.png 'https://github.com/jellyfin/jellyfin-ux/blob/master/logos/PNG-background-space/jellyfin-horizontal--color-on-light.png?raw=true'

GitHub Release - Make your build.yaml

See Metadata.md for explanation

name: Template
guid: eb5d7894-8eef-4b36-aa6f-5d124e828ce2
imageUrl: https://github.com/lordwelch/jellyfin-plugin-template/raw/refs/heads/master/logo.png
image: logo.png
targetAbi: 10.11.11.0
framework: net9.0
owner: lordwelch
overview: A template for making jellyfin plugins.
category: Other
description: |
  This plugin is an template for making actually useful plugins

GitHub Release - Push changes

git add .
git commit -m 'Update for use with traitorous-jprm'
git push origin master

GitHub Release - Make a temporary directory for build assets (optional)

mkdir assets
cd assets

GitHub Release - Build and package the plugin

jprm --verbosity debug repo build -c 'this is a changelog' --version 6.0.0.0 ./manifest.json ../

GitHub Release - Create a release on github

gh release create -R lordwelch/jellyfin-plugin-template 6.0.0.0 --title "v6.0.0.0" --notes "This is an example release for demonstrating https://gitea.narnian.us/lordwelch/traitorous-jprm" manifest.json ./artifacts/*

GitHub Release - Activate repo in Jellyfin

Plugin repository url for this example is: https://github.com/lordwelch/jellyfin-plugin-template/releases/latest/download/manifest.json

Gitea Release

Gitea Release - Make a plugin

Replace https://gitea.narnian.us/lordwelch/jellyfin-plugin-template with your gitea repository

git clone https://github.com/jellyfin/jellyfin-plugin-template
cd jellyfin-plugin-template
git remote set-url origin https://gitea.narnian.us/lordwelch/jellyfin-plugin-template

Gitea Release - Migrate to new sln file (optional)

dotnet sln migrate Jellyfin.Plugin.Template.sln
rm Jellyfin.Plugin.Template.sln

Gitea Release - Get a logo (optional)

curl -Lo logo.png 'https://github.com/jellyfin/jellyfin-ux/blob/master/logos/PNG-background-space/jellyfin-horizontal--color-on-light.png?raw=true'

Gitea Release - Make your build.yaml

See Metadata.md for explanation of properties

📝 Note: https://gitea.narnian.us doesn't let you view raw files until you login, so I upload the logo to the release so that this actually works

name: Template
guid: eb5d7894-8eef-4b36-aa6f-5d124e828ce2
imageUrl: https://gitea.narnian.us/lordwelch/jellyfin-plugin-template/releases/download/latest/logo.png
image: logo.png
targetAbi: 10.11.11.0
framework: net9.0
owner: lordwelch
overview: A template for making jellyfin plugins.
category: Other
description: |
  This plugin is an template for making actually useful plugins

Gitea Release - Push changes

git add .
git commit -m 'Update for use with traitorous-jprm'
git push origin master

Gitea Release - Make a temporary directory for build assets (optional)

mkdir assets
cd assets

Gitea Release - Build and package the plugin

jprm --verbosity debug repo build -c 'this is a changelog' --version 6.0.0.0 ./manifest.json ../

Gitea Release - Create a release on Gitea

tea release create --tag 6.0.0.0 --title "v6.0.0.0" --note "This is an example release for demonstrating https://gitea.narnian.us/lordwelch/traitorous-jprm"
tea release asset create 6.0.0.0 ../logo.png manifest.json artifacts/*

OR

response=$(
curl --request POST \
  --url https://gitea.narnian.us/api/v1/repos/lordwelch/jellyfin-plugin-template/releases \
  --header 'Authorization: token <api key>' \
  --header 'Content-Type: application/json' \
  --data '{ "body": "This is an example release for demonstrating https://gitea.narnian.us/lordwelch/traitorous-jprm", "draft": false, "name": "v6.0.0.0", "prerelease": false, "tag_name": "6.0.0.0"}'
)
upload_url=${response##*\"upload_url\":\"}  # removes everything before the json value we need "upload_url"
upload_url=${upload_url%%\"*}               # removes everything after the json value we need
for filename in ../logo.png manifest.json artifacts/*; do
  curl --request POST \
    --url "$upload_url?name=${filename##*/}" \
    --header 'Authorization: token <api key>' \
    --header 'Content-Type: application/octet-stream' \
    --data-binary "@${filename}"
done

Gitea Release - Activate repo in Jellyfin

Plugin repository url for this example is: https://gitea.narnian.us/lordwelch/jellyfin-plugin-template/releases/download/latest/manifest.json

Gitea Packages

Gitea Packages - Make a plugin

Replace https://gitea.narnian.us/lordwelch/jellyfin-plugin-template with your gitea repository

git clone https://github.com/jellyfin/jellyfin-plugin-template
cd jellyfin-plugin-template
git remote set-url origin https://gitea.narnian.us/lordwelch/jellyfin-plugin-template

Gitea Packages - Migrate to new sln file (optional)

dotnet sln migrate Jellyfin.Plugin.Template.sln
rm Jellyfin.Plugin.Template.sln

Gitea Packages - Get a logo (optional)

curl -Lo logo.png 'https://github.com/jellyfin/jellyfin-ux/blob/master/logos/PNG-background-space/jellyfin-horizontal--color-on-light.png?raw=true'

Gitea Packages - Make your build.yaml

See Metadata.md for explanation of properties

(https://gitea.narnian.us doesn't let you view raw files until you login, so I upload the logo and manifest to a package version called 'assets')

name: Template
guid: eb5d7894-8eef-4b36-aa6f-5d124e828ce2
imageUrl: https://gitea.narnian.us/api/packages/lordwelch/generic/jellyfin-plugin-template/assets/oidc-authentication_6.0.0.0.zip
image: logo.png
targetAbi: 10.11.11.0
framework: net9.0
owner: lordwelch
overview: A template for making jellyfin plugins.
category: Other
description: |
  This plugin is an template for making actually useful plugins

Gitea Packages - Push changes

git add .
git commit -m 'Update for use with traitorous-jprm'
git push origin master

Gitea Packages - Make a temporary directory for build assets (optional)

mkdir assets
cd assets

Gitea Packages - Build and package the plugin

Note the custom url format used here

jprm --verbosity debug repo build --url 'https://{hostname}/api/packages/{owner}/generic/{project}/{version}/{slug}_{version}.zip' -c 'this is a changelog' --version 6.0.0.0 ./manifest.json ../

Gitea Packages - Create a package on Gitea

function upload_package() {
  token=$1
  package_name=$2
  version=$3
  filename=$4
  # First delete any package that exists. Needed for if we upload a manifest for the next version
  url="https://gitea.narnian.us/api/packages/lordwelch/generic/$package_name/$version/${filename##*/}"
  curl -X DELETE \
    --header "Authorization: token $token" \
    "$url" >/dev/null 2>&1
  curl -X PUT \
    --header "Authorization: token $token" \
    "$url" \
    --upload-file "$filename"
}

for file in artifacts/*; do
  upload_package '<api key>' jellyfin-plugin-template 6.0.0.0 "$file"
done
upload_package '<api key>' jellyfin-plugin-template assets ./manifest.json
upload_package '<api key>' jellyfin-plugin-template assets ../logo.png

Gitea Packages - Link package to repository (optional)

Go to https://gitea.narnian.us/lordwelch/-/packages/settings/generic/jellyfin-plugin-template and link to jellyfin-plugin-template

Gitea Packages - Activate repo in Jellyfin

Plugin repository url for this example is: https://gitea.narnian.us/api/packages/lordwelch/generic/jellyfin-plugin-template/assets/manifest.json

Why is it called traitorous-jprm?

Because I own the traitorous.enterprises domain.

And if I put traitorous in the name people probably won't take it too seriously

Metadata

Release files for traitorous-jprm 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for traitorous-jprm 1.1.0
File Size Uploaded Provenance Actions
traitorous_jprm-1.1.0.tar.gz 41.9 kB Without provenance Details for traitorous_jprm-1.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for traitorous-jprm 1.1.0
File Interpreter ABI Platform Actions
traitorous_jprm-1.1.0-py3-none-any.whl Python 3 none any Details for traitorous_jprm-1.1.0-py3-none-any.whl

Total release size: 64.7 kB

Release files / traitorous_jprm-1.1.0.tar.gz

Download URL traitorous_jprm-1.1.0.tar.gz
Size 41.9 kB
Tags Source
SHA-256 checksum
How to use checksums
707e059aa20d01baef9a250dd98943c953c6ed1250107ea931f389e547557a9b
BLAKE2b-256 checksum
How to use checksums
9d5017003b778ed526f005639a5c3bc2cf0141dbbe8aa0f41061ff671658f94d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / traitorous_jprm-1.1.0-py3-none-any.whl

Download URL traitorous_jprm-1.1.0-py3-none-any.whl
Size 22.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c5be48f68ae98b26e9bfb012dbd12f574c85fca733b450753fbf4893dd7087ef
BLAKE2b-256 checksum
How to use checksums
df511629ee28984f112093fce17500acb230ac3bf1251b83ba80acf2932ea98c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Security for traitorous-jprm 1.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page