Skip to content

fixed the syntax error #5

fixed the syntax error

fixed the syntax error #5

Workflow file for this run

name: Deploy to GitHub Pages
on:
push:
branches:
- portfolio # Change this to your default branch
jobs:
build:
runs-on: ubuntu-latest
# <--- Here we need to add permissions: contents: write
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22.3.0'
- name: Install dependencies
run: npm install
- name: Build project
run: npm run build
- name: Upload dist as artifact
uses: actions/upload-artifact@v4
with:
name: github-pages-artifact
path: dist
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist
publish_branch: gh-pages # Publish to this default gh-pages branch