Files
v10/.github/workflows/cd.yml
T
Darius CepulisandClaude Opus 4.6 1cab75c2ef feat(cd): switch to npm trusted publishers
Replace NPM_TOKEN with OIDC-based trusted publishing. Bump Node to
24 LTS (bundles npm 11 which supports OIDC). Add @videojs/store and
@videojs/element to release-please config.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 15:21:38 -06:00

72 lines
2.1 KiB
YAML

name: Deployment
concurrency: production
on:
push:
branches:
- main
# To use Turborepo Remote Caching, set the following environment variables.
# env:
# TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
# TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
jobs:
release:
runs-on: ubuntu-latest
environment: production
permissions:
contents: write
pull-requests: write
id-token: write
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
config-file: .github/release-please/release-please-config.json
manifest-file: .github/release-please/.release-please-manifest.json
- uses: actions/checkout@v5
# these if statements ensure that a publication only occurs when
# a new release is created:
if: ${{ steps.release.outputs.releases_created == 'true' }}
with:
fetch-depth: 0 # Fetch all history for all tags and branches
- name: Setup pnpm
if: ${{ steps.release.outputs.releases_created == 'true' }}
uses: pnpm/action-setup@v4
- uses: actions/setup-node@v5
if: ${{ steps.release.outputs.releases_created == 'true' }}
with:
node-version-file: '.nvmrc'
registry-url: 'https://registry.npmjs.org'
- name: Install
if: ${{ steps.release.outputs.releases_created == 'true' }}
run: pnpm i --frozen-lockfile
- name: Cache turbo build setup
if: ${{ steps.release.outputs.releases_created == 'true' }}
uses: actions/cache@v5
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-
- name: Clean
if: ${{ steps.release.outputs.releases_created == 'true' }}
run: pnpm clean
- name: Build
if: ${{ steps.release.outputs.releases_created == 'true' }}
run: pnpm build:packages
- name: Publish
if: ${{ steps.release.outputs.releases_created == 'true' }}
run: pnpm -r publish --filter "./packages/*" publish --access public --provenance --tag next --no-git-checks