update workflows

This commit is contained in:
semanticdata 2024-03-07 13:07:56 -06:00
parent ac5f363932
commit a6f9d26c55
2 changed files with 60 additions and 9 deletions

53
.github/workflows/deploy-pnpm.yml vendored Normal file
View File

@ -0,0 +1,53 @@
name: Quartz - Deploy to GitHub Pages (pnpm)
on:
workflow_dispatch:
# push:
# branches:
# - main
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
install:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
name: Checkout
with:
fetch-depth: 0 # Fetch all history for git info
- uses: actions/setup-node@v4
name: Setup Node
with:
node-version: 18
build:
needs: install
runs-on: ubuntu-latest
steps:
- name: Install Dependencies
run: npm i
- name: Build Quartz Site
run: npx quartz build
- uses: actions/upload-pages-artifact@v3
name: Upload artifact
with:
path: public
deploy:
needs: build
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
uses: actions/deploy-pages@v4
id: deployment

View File

@ -1,4 +1,4 @@
name: Quartz - Deploy to GitHub Pages
name: Quartz - Deploy to GitHub Pages (npm)
on:
workflow_dispatch:
@ -19,20 +19,18 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4 # v3
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for git info
- uses: actions/setup-node@v3 # v3
- uses: actions/setup-node@v4
with:
node-version: 20.11.0 # 18.14
- name: PNPM Install
uses: ./.github/actions/pnpm-install
node-version: 18
- name: Install Dependencies
run: pnpm i # was npm i
run: npm i
- name: Build Quartz
run: npx quartz build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3 # v2
uses: actions/upload-pages-artifact@v3
with:
path: public
@ -45,4 +43,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4 # v2
uses: actions/deploy-pages@v4