-
Notifications
You must be signed in to change notification settings - Fork 8
37 lines (31 loc) · 822 Bytes
/
deploy-docs.yml
File metadata and controls
37 lines (31 loc) · 822 Bytes
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
name: Documentation
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
permissions:
contents: write
jobs:
generate-and-deploy-docs:
name: Generate and Deploy
runs-on: macos-26
steps:
- name: Checkout repository
uses: actions/checkout@v5
- name: Cache SwiftPM artifacts
uses: actions/cache@v4
with:
path: |
~/.swiftpm
.build
key: ${{ runner.os }}-swiftpm-${{ hashFiles('**/Package.swift') }}
restore-keys: |
${{ runner.os }}-swiftpm-
- name: Generate documentation
run: Scripts/generate-docs.sh
- name: Deploy to GitHub Pages
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
Scripts/deploy-docs.sh main