mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-14 18:01:06 +00:00
36 lines
1 KiB
YAML
36 lines
1 KiB
YAML
on:
|
|
push:
|
|
tags:
|
|
- "v*"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
id-token: write
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "18.x"
|
|
registry-url: "https://registry.npmjs.org"
|
|
- name: Build
|
|
run: |
|
|
npm install --force
|
|
npm run build:docs & npm run build:lib
|
|
- name: Publish package (stable)
|
|
if: ${{ ! contains(github.ref, '-next') }}
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
|
|
|
|
# Currently, only npm supports publishing packages with provenance
|
|
# https://docs.npmjs.com/generating-provenance-statements
|
|
run: |
|
|
npm publish --provenance --access public
|
|
- name: Publish package (next)
|
|
if: ${{ contains(github.ref, '-next') }}
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
|
|
run: |
|
|
npm publish --provenance --access public --tag next
|