Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file removed .codespell.ignore-words
Empty file.
77 changes: 77 additions & 0 deletions .github/workflows/docs-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
name: Build and Deploy Docs to GitHub Pages

on:
push:
branches:
- main
- bslv2-doc # v0: testing on feature branch
workflow_dispatch:

# Grant GITHUB_TOKEN the permissions needed
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment
concurrency:
group: pages-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
name: Build BSL Docs
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.10"

- name: Install uv
uses: astral-sh/setup-uv@v6
with:
enable-cache: true

- name: Install BSL Python dependencies
run: uv sync --extra examples --extra viz-altair

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
cache-dependency-path: docs/package-lock.json

- name: Install dependencies
working-directory: ./docs
run: npm ci

- name: Build BSL data and static site
working-directory: ./docs
run: npm run build

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./docs/dist

deploy:
name: Deploy to GitHub Pages
# Deploy from main and bslv2-doc branches (v0: testing)
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/bslv2-doc'
needs: build
runs-on: ubuntu-latest

environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ repos:
- id: codespell
additional_dependencies:
- tomli
args: [--ignore-words=.codespell.ignore-words, --skip=*.ipynb]
args: ["--skip=*.ipynb,**/node_modules/**,**/package-lock.json", "--ignore-words-list=hastable"]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.11.13
Expand Down
Loading