Skip to content

Vehicle Setup: JSON-driven QML page generation for Power and Safety #795

Vehicle Setup: JSON-driven QML page generation for Power and Safety

Vehicle Setup: JSON-driven QML page generation for Power and Safety #795

Workflow file for this run

name: Docs
on:
push:
branches:
- master
- 'Stable*'
paths:
- 'docs/**'
- 'package*.json'
pull_request:
paths:
- 'docs/**'
- 'package*.json'
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
permissions:
contents: read
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Harden Runner
uses: step-security/harden-runner@v2
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@v6
- name: Setup Node
uses: actions/setup-node@v6
with:
node-version: 'lts/*'
cache: npm
- name: Install dependencies
run: npm ci
- name: Build with VitePress
run: |
npm run docs:build
touch docs/.vitepress/dist/.nojekyll
- name: Upload artifact
uses: actions/upload-artifact@v7
with:
name: qgc_docs_build
path: docs/.vitepress/dist/
retention-days: 1
deploy:
if: (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && github.repository_owner == 'mavlink'
needs: build
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Harden Runner
uses: step-security/harden-runner@v2
with:
egress-policy: audit
- name: Deploy docs
uses: ./.github/actions/deploy-docs
with:
artifact-name: qgc_docs_build
target-repo: mavlink/docs.qgroundcontrol.com
target-branch: master
deploy-token: ${{ secrets.PX4BUILDBOT_ACCESSTOKEN }}
source-branch: ${{ env.BRANCH_NAME }}
commit-message: 'QGC docs build update'