Skip to content
# This is a basic workflow to help you get started with Actions
name: Deploy site to Pages
# Controls when the workflow will run
on:
workflow_dispatch:
push:
branches: ["main"]
pull_request:
types: [opened, synchronize, reopen]
branches: ["main"]
permissions:
contents: write
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- uses: actions/setup-node@v2
with:
node-version: 18
cache: "npm"
- name: Install dependencies
run: npm install
# Runs a set of commands using the runners shell
- name: Run a multi-line script
run: |
npm run build
- name: Run Prettier
#fix markdown files in /blog
run: npm run prettier:fix
#- name: Run Embedme
#run: npm run embedme:fix
#- name: Proofread PR
# uses: awreck/proofread-action@v1
# id: proofread
# with:
# token: ${{ secrets.GITHUB_TOKEN }} # Required to write a PR review
- name: Deploy to GitHub Pages
uses: JamesIves/[email protected]
with:
folder: build
branch: gh-pages