Skip to content

Update OpenAPI to unstable #1149

Update OpenAPI to unstable

Update OpenAPI to unstable #1149

name: SDK Unstable Publish
on:
workflow_dispatch:
push:
branches:
- openapi-unstable
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
if: ${{ github.repository == 'jellyfin/jellyfin-sdk-typescript' }}
steps:
- name: Check out Git repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: openapi-unstable
- name: Set up Node.js
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: 20
check-latest: true
cache: npm
registry-url: https://registry.npmjs.org
- name: Update package version
run: |
VERSION="0.0.0-unstable.$(date +%Y%m%d%H%M)+commit.$(git rev-parse HEAD)" && \
PACKAGE="$(jq --arg v "$VERSION" '.version = $v' package.json)" && \
echo -E "${PACKAGE}" > package.json
- name: Install Node.js dependencies
run: npm ci --no-audit
- name: Publish the SDK to npm
run: npm publish --tag unstable --provenance
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}