Skip to content

Bump actions/setup-node from 6.0.0 to 6.2.0 (#97) #5

Bump actions/setup-node from 6.0.0 to 6.2.0 (#97)

Bump actions/setup-node from 6.0.0 to 6.2.0 (#97) #5

Workflow file for this run

name: Publish
on:
push:
branches:
- main
permissions:
contents: write
concurrency:
group: publish
cancel-in-progress: true
jobs:
check:
name: Check for Release
runs-on: ubuntu-latest
outputs:
should-publish: ${{ steps.check.outputs.should-publish }}
steps:
- name: Checkout
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
- name: Check for .release-plan.json
id: check
run: |
if [ -f ".release-plan.json" ]; then
echo "should-publish=true" >> $GITHUB_OUTPUT
else
echo "should-publish=false" >> $GITHUB_OUTPUT
fi
publish:
name: Publish
runs-on: ubuntu-latest
timeout-minutes: 15
needs: check
if: needs.check.outputs.should-publish == 'true'
steps:
- name: Checkout
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
with:
fetch-depth: 0
- name: Setup pnpm
uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
- name: Setup Node
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
with:
node-version-file: package.json
cache: pnpm
registry-url: "https://registry.npmjs.org"
- name: Install Dependencies
run: pnpm install --frozen-lockfile
- name: Publish to npm
run: npx release-plan publish
env:
GITHUB_AUTH: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}