updated templates and workflows #69
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# $schema: https://json.schemastore.org/github-workflow.json | |
name: Release | |
defaults: | |
run: | |
shell: bash | |
env: | |
FORCE_COLOR: true | |
on: | |
push: | |
branches: | |
- main | |
- next | |
jobs: | |
release: | |
name: Release | |
if: github.repository == 'jcayzac/copepod-modules' | |
runs-on: ubuntu-latest | |
permissions: | |
actions: read | |
contents: write | |
id-token: write | |
pull-requests: write | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v4 | |
- name: Setup PNPM | |
uses: pnpm/action-setup@v4 | |
- name: Setup Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
registry-url: https://registry.npmjs.org/ | |
cache: pnpm | |
- name: Install Dependencies | |
run: pnpm install | |
- name: Building Packages | |
run: pnpm build # | |
- name: Create Release PR or Publish | |
uses: changesets/action@v1 | |
with: | |
version: pnpm changeset version | |
publish: pnpm exec changeset publish | |
commit: '[ci] release' | |
title: '[ci] release' | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | |
NPM_CONFIG_PROVENANCE: true |