Skip to content

Merge pull request #4429 from FlowFuse/ginnyporlaje-pro-patch-4 #4577

Merge pull request #4429 from FlowFuse/ginnyporlaje-pro-patch-4

Merge pull request #4429 from FlowFuse/ginnyporlaje-pro-patch-4 #4577

Workflow file for this run

name: Build Site
on:
workflow_dispatch:
push:
branches:
- main
schedule:
- cron: "30 9 * * *"
- cron: "5 16 * * 3,4"
jobs:
build_deploy:
if: ${{ github.repository == 'FlowFuse/website' }}
runs-on: ubuntu-latest
steps:
- name: Check out website repository
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
path: 'website'
- name: Check out FlowFuse/flowfuse repository (to access the docs)
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
repository: 'FlowFuse/flowfuse'
ref: main
path: 'flowfuse'
- name: Generate a token
id: generate_token
uses: tibdex/github-app-token@3beb63f4bd073e61482598c45c71c1019b59b73a # v2.1.0
with:
app_id: ${{ secrets.GH_BOT_APP_ID }}
private_key: ${{ secrets.GH_BOT_APP_KEY }}
- name: Check out FlowFuse/blueprint-library repository (to access the blueprints)
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
repository: 'FlowFuse/blueprint-library'
ref: main
path: 'blueprint-library'
token: ${{ steps.generate_token.outputs.token }}
- name: Install jq
run: sudo apt-get -qy install jq
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
with:
cache: 'npm'
cache-dependency-path: './website/package-lock.json'
- run: npm run docs
working-directory: 'website'
- run: npm run blueprints
working-directory: 'website'
- name: Commit Latest Docs
run: |
cd ./website
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add src/docs/* -A -f
git commit -a -m "Bot: update docs"
- name: Commit Latest Blueprints
run: |
cd ./website
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add src/blueprints/* -A -f
git commit -a -m "Bot: update blueprints"
- name: Push to 'live' branch
uses: ad-m/github-push-action@77c5b412c50b723d2a4fbc6d71fb5723bcd439aa # v1.0.0
with:
directory: './website'
branch: live
force: true