Skip to content

Enable Google Analytics #472

Enable Google Analytics

Enable Google Analytics #472

Workflow file for this run

name: Build
on:
push:
workflow_call:
inputs:
commit: # For release version bump commit
required: false
type: string
environment:
required: false
type: string
prettyfy: # For HTML diff
required: false
type: boolean
skip_lints_tests:
required: false
type: boolean
sphinx_github_branch: # For HTML diff and production (tag vs branch)
required: false
type: string
jobs:
Build:
runs-on: ubuntu-latest
environment: "${{ inputs.environment }}" # Note: can be empty
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: "${{ inputs.commit }}"
- name: Setup Dependencies
uses: ./.github/actions/deps
- name: Run Tests
if: '! inputs.skip_lints_tests'
env:
PY_COLORS: 1
run: make test
- name: Run Lints
if: '! inputs.skip_lints_tests'
run: make lint
- name: Run Integration Tests
if: '! inputs.skip_lints_tests'
run: make it
- name: Build
env: # Note: these can be empty
SPHINX_GITHUB_BRANCH: "${{ inputs.sphinx_github_branch }}"
SPHINX_HTML_BASEURL: "${{ vars.SPHINX_HTML_BASEURL }}"
run: make docs
- name: Copy .gitignore into html output directory # For diff storage branch
run: cp --no-clobber --verbose .gitignore docs/_build/html/
- name: Prettify
if: inputs.prettyfy
run: |
PS4="\n\033[1;33m$PS4\033[0m"
set -euxo pipefail
npm install -g prettier@3.3.2 @prettier/plugin-xml@3.4.1
prettier --write "docs/_build/html/**/*.{js,css,html,xml}"
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: html
path: docs/_build/html
if-no-files-found: error
include-hidden-files: true