Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .eslintignore

This file was deleted.

4 changes: 0 additions & 4 deletions .eslintrc

This file was deleted.

67 changes: 0 additions & 67 deletions .github/workflows/preview-publish.yml

This file was deleted.

91 changes: 78 additions & 13 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,37 +3,102 @@ on:
push:
branches:
- main
pull_request:
branches:
- main

permissions:
contents: read # for checkout
contents: read

jobs:
build:
name: Build & Verify
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v4
with:
node-version: "lts/*"
registry-url: "https://registry.npmjs.org"
cache: "npm"

- name: Update npm
run: npm install -g npm@11.5.1

- run: npm install
- run: npx nuxi prepare
- run: npm run dev:build
- run: npm run lint
- run: npm run prepack

- name: Verify the integrity of provenance attestations and registry signatures
run: npm audit signatures

release:
name: Release
needs: build
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests
id-token: write # to enable use of OIDC for npm provenance
id-token: write # required for OIDC / Trusted Publishers
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v4
with:
node-version: "lts/*"
- name: Configure npm for Authentication
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_NUXT_TOKEN }}" >> ~/.npmrc
echo "@prisma:registry=https://registry.npmjs.org/" >> ~/.npmrc
- run: npm clean-install
registry-url: "https://registry.npmjs.org"
cache: "npm"

- name: Update npm
run: npm install -g npm@11.5.1

- run: npm install
- run: npx nuxi prepare
- run: npm run dev:build
- run: npm run lint
- run: npm run prepack
- name: Verify the integrity of provenance attestations and registry signatures for installed dependencies
run: npm audit signatures

- name: Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_NUXT_TOKEN }}
run: npx semantic-release

experimental-release:
name: Experimental Dev Release
needs: build
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
permissions:
contents: write # For publishing to GitHub releases
id-token: write # required for OIDC / Trusted Publishers
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v4
with:
node-version: "lts/*"
registry-url: "https://registry.npmjs.org"
cache: "npm"

- name: Update npm
run: npm install -g npm@11.5.1

- run: npm install
- run: npx nuxi prepare

- name: Build module
run: npm run prepack

- name: Set Experimental Version
run: npm version --no-git-tag-version 0.0.0-experimental-${GITHUB_SHA::7}

- name: Publish Experimental Release
run: npm publish --access public --tag experimental --ignore-scripts
Loading