Skip to content

feat: migrate from deno fmt to prettier (#98) #11

feat: migrate from deno fmt to prettier (#98)

feat: migrate from deno fmt to prettier (#98) #11

Workflow file for this run

name: Deploy
on:
push:
branches: [main]
workflow_dispatch:
jobs:
deploy:
name: Deploy to Cloudflare
runs-on: ubuntu-latest
environment: production
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "23"
- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: latest
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Setup pnpm cache
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Run tests
run: pnpm test --run
- name: Build web client
run: pnpm build:prod
- name: Deploy worker
run: pnpm deploy:worker
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
- name: Deploy web client
run: wrangler pages deploy dist --project-name anode
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}