-
Notifications
You must be signed in to change notification settings - Fork 1
52 lines (48 loc) · 1.57 KB
/
documentation.yml
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
name: Deploy Documentation
on:
push:
tags:
- '*'
workflow_dispatch:
# Set permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages.
permissions:
contents: read
id-token: write
pages: write
# Allow one concurrent deployment. Do not cancel in-flight deployments because we don't want assets to be in a
# a semi-deployed state.
concurrency:
group: "documentation"
cancel-in-progress: false
jobs:
deploy-documentation:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: macos-15
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set Up GitHub Pages
uses: actions/configure-pages@v3
- name: Build Documentation
run: |
xcodebuild docbuild \
-scheme HierarchyResponder \
-derivedDataPath ./build \
-destination 'generic/platform=iOS';
mkdir public;
$(xcrun --find docc) process-archive \
transform-for-static-hosting ./build/Build/Products/Debug-iphoneos/HierarchyResponder.doccarchive \
--hosting-base-path HierarchyResponder \
--output-path ./public;
- name: Create index.html
run: |
echo "<script>window.location.href += \"/documentation/hierarchyresponder\"</script>" > ./public/index.html;
- name: Upload Documentation Artifact to GitHub Pages
uses: actions/upload-pages-artifact@v1
with:
path: public
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2