Skip to content

test: gh pages deploy #334

test: gh pages deploy

test: gh pages deploy #334

Workflow file for this run

name: GitHub Pages Publish
on:
push:
branches: [main]
env:
FONTAWESOME_PACKAGE_TOKEN: ${{ secrets.FONTAWESOME_PACKAGE_TOKEN }}
jobs:
gh-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: gh-deploy
- uses: actions/setup-node@v4
with:
node-version: 18
registry-url: https://registry.npmjs.org
cache: 'yarn'
- name: Merge
uses: devmasx/merge-branch@master
with:
type: now
from_branch: main
target_branch: gh-deploy
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Install
run: yarn install
- name: Build
working-directory: '.'
run: yarn build:pages
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: build
deploy:
# Add a dependency to the build job
needs: gh-deploy
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source
# Deploy to the github-pages environment
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4