Skip to content

Commit

Permalink
Merge pull request #261 from thornbill/publish-workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
thornbill authored Sep 15, 2022
2 parents fe8540d + 7eb8f72 commit ea8720a
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 3 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/sdk-publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: SDK Publish

on:
release:
types: [published]

jobs:
publish:
runs-on: ubuntu-latest
if: ${{ github.repository == 'jellyfin/jellyfin-sdk-typescript' }}
steps:
- name: Check out Git repository
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3

- name: Set up Node.js
uses: actions/setup-node@2fddd8803e2f5c9604345a0b591c3020ee971a93 # tag=v3
with:
node-version: 16
check-latest: true
cache: npm

- name: Install Node.js dependencies
run: npm ci --no-audit

- name: Publish the SDK to npm
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
access=public
lockfile-version=3
save-exact=true
3 changes: 0 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@
"type": "git",
"url": "https://github.com/jellyfin/jellyfin-sdk-typescript.git"
},
"publishConfig": {
"access": "public"
},
"scripts": {
"build": "npm run build:generated-client && npm run build:sdk",
"build:generated-client": "openapi-generator-cli generate",
Expand Down

0 comments on commit ea8720a

Please sign in to comment.