Skip to content

Update public content 2025-02-17 (#58) #48

Update public content 2025-02-17 (#58)

Update public content 2025-02-17 (#58) #48

Workflow file for this run

name: Publish to Quartz
on:
push:
branches:
- v4
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.PERSONAL_TOKEN }}
submodules: false # We'll initialize submodules manually
- name: Update Git config
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "actions@github.com"
# Configure Git to use HTTPS instead of SSH with token authentication
git config --global url."https://${{ secrets.PERSONAL_TOKEN }}@github.com/".insteadOf "https://github.com/"
- name: Initialize and update submodules
run: |
# Initialize submodules with the configured authentication
git submodule init
git submodule update --remote
cd _obsidian
git checkout main
cd ..
git add _obsidian
git commit -m "Update obsidian content" || echo "No changes to commit"
git push || echo "No changes to push"
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install Dependencies
run: npm ci
- name: Build Site
run: npx quartz build
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.DEPLOY_KEY }}
publish_branch: gh-pages
publish_dir: ./public