Repository navigation
62 lines (51 loc) · 2.14 KB
/
Copy pathwebsite.yml
File metadata and controls
62 lines (51 loc) · 2.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# SPDX-FileCopyrightText: 2026 The RISE Project
# SPDX-License-Identifier: MIT
name: Build and deploy website
on:
push:
branches: [main]
paths:
- "docs/**"
- "ci_scripts/dashboard/**"
workflow_dispatch:
concurrency:
group: website
cancel-in-progress: false
queue: ${{ github.ref == 'refs/heads/main' && 'single' || 'max' }}
jobs:
deploy:
if: (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
- name: Generate package pages from YAML
run: uv run --isolated --with-requirements ci_scripts/requirements.txt ci_scripts/generate_packages_doc.py
- name: Restore the dashboard's pypi.org response cache
id: dashboard-requests-cache
uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: requests-cache.sqlite
key: requests-cache-main-${{ github.run_id }}
restore-keys: requests-cache-main-
- name: Generate the dashboard
run: uv run --isolated --with-requirements ci_scripts/requirements.txt ci_scripts/dashboard/build.py --output-dir docs/dashboard
- name: Build with Jekyll
uses: actions/jekyll-build-pages@44a6e6beabd48582f863aeeb6cb2151cc1716697 # v1.0.13
with:
source: ./docs
destination: ./_site
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@84c30a85c19949d7eee79c4ff27748b70285e453 # v4.1.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./_site
cname: pypi.riseproject.dev
- name: Save the dashboard's pypi.org response cache
if: github.ref == 'refs/heads/main'
uses: actions/cache/save@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: requests-cache.sqlite
key: ${{ steps.dashboard-requests-cache.outputs.cache-primary-key }}