mirror of
https://github.com/foomo/foomo-docs.git
synced 2025-10-16 12:35:40 +00:00
51 lines
1.0 KiB
YAML
51 lines
1.0 KiB
YAML
# https://docusaurus.io/docs/deployment#triggering-deployment-with-github-actions
|
|
name: publish
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
name: Build Docusaurus
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- uses: actions/setup-node@v5
|
|
with:
|
|
node-version: "20.x"
|
|
|
|
- name: Enable Corepack
|
|
run: corepack enable
|
|
|
|
- name: Release to GitHub Pages
|
|
working-directory: foomo
|
|
run: |
|
|
yarn install --frozen-lockfile
|
|
npm run build
|
|
|
|
- uses: actions/upload-pages-artifact@v3
|
|
with:
|
|
path: foomo/build
|
|
|
|
deploy:
|
|
name: Deploy to GitHub Pages
|
|
runs-on: ubuntu-latest
|
|
needs: build
|
|
|
|
permissions:
|
|
pages: write
|
|
id-token: write
|
|
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
|
|
steps:
|
|
- name: Deploy to GitHub Pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@v4
|