fix(ci): setup node and pnpm
This commit is contained in:
13
.github/workflows/deploy-preview.yml
vendored
13
.github/workflows/deploy-preview.yml
vendored
@@ -14,15 +14,26 @@ jobs:
|
|||||||
name: Deploy preview
|
name: Deploy preview
|
||||||
if: ${{ github.repository == 'dot013/.www-new' }}
|
if: ${{ github.repository == 'dot013/.www-new' }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
node-version: [20]
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
- name: Setup go
|
- name: Setup pnpm
|
||||||
|
uses: pnpm/action-setup@v3
|
||||||
|
- name: Setup Node.js ${{ matrix.node-version }}
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: ${{ matrix.node-version }}
|
||||||
|
cache: 'pnpm'
|
||||||
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v5
|
uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: '1.22.2'
|
go-version: '1.22.2'
|
||||||
- name: Build
|
- name: Build
|
||||||
run: |
|
run: |
|
||||||
|
pnpm install
|
||||||
go install github.com/a-h/templ/cmd/templ@latest
|
go install github.com/a-h/templ/cmd/templ@latest
|
||||||
make build-vercel
|
make build-vercel
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
|
|||||||
8
.github/workflows/deploy.yml
vendored
8
.github/workflows/deploy.yml
vendored
@@ -13,12 +13,20 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
- name: Setup pnpm
|
||||||
|
uses: pnpm/action-setup@v3
|
||||||
|
- name: Setup Node.js ${{ matrix.node-version }}
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: ${{ matrix.node-version }}
|
||||||
|
cache: 'pnpm'
|
||||||
- name: Setup go
|
- name: Setup go
|
||||||
uses: actions/setup-go@v5
|
uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: '1.22.2'
|
go-version: '1.22.2'
|
||||||
- name: Build
|
- name: Build
|
||||||
run: |
|
run: |
|
||||||
|
pnpm install
|
||||||
go install github.com/a-h/templ/cmd/templ@latest
|
go install github.com/a-h/templ/cmd/templ@latest
|
||||||
make build-vercel
|
make build-vercel
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
|
|||||||
Reference in New Issue
Block a user