Skip to content

chore(deps): lock file maintenance #1601

chore(deps): lock file maintenance

chore(deps): lock file maintenance #1601

name: Build and publish
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
repository_dispatch:
jobs:
build:
name: ${{ github.ref == 'refs/heads/main' && 'Publish' || 'Test build' }}
runs-on: self-hosted
if: ${{ github.event_name == 'pull_request' }}
steps:
- name: Checkout repository
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Set up pnpm
uses: pnpm/action-setup@v2
with:
version: 8
- name: Set up node
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4
with:
node-version-file: ".nvmrc"
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: ${{ github.ref == 'refs/heads/main' && 'Build ans publish' || 'Test worker build' }}
uses: cloudflare/wrangler-action@7c01cc48d88a1f83b4716e0557c168854a9dcdb8 # v3.4.1
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CF_ACCOUNT_ID }}
command: ${{ github.ref == 'refs/heads/main' && 'deploy' || 'deploy --dry-run' }}