Skip to content

Commit f7f0efa

Browse files
Create docfx-pages.yml
1 parent 24eefb2 commit f7f0efa

File tree

1 file changed

+93
-0
lines changed

1 file changed

+93
-0
lines changed

.github/workflows/docfx-pages.yml

+93
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
name: docfx for GitHub Pages
2+
3+
on:
4+
# Runs on pushes targeting the default branch
5+
push:
6+
branches:
7+
- 'main'
8+
##- 'releases/**'
9+
release:
10+
types: [published]
11+
12+
# Allows you to run this workflow manually from the Actions tab
13+
workflow_dispatch:
14+
15+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
16+
permissions:
17+
contents: read
18+
pages: write
19+
id-token: write
20+
21+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
22+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
23+
concurrency:
24+
group: "pages"
25+
cancel-in-progress: false
26+
27+
jobs:
28+
# Single deploy job since we're just deploying
29+
deploy:
30+
environment:
31+
name: github-pages
32+
url: ${{ steps.deployment.outputs.page_url }}
33+
runs-on: ubuntu-latest
34+
35+
36+
#########################################
37+
###### sator-imaging/docfx-pages ######
38+
#########################################
39+
steps:
40+
41+
# for extensibility, docfx-pages does NOT checkout your repository.
42+
# so you need to checkout manually prior to sator-imaging/docfx-pages.
43+
- name: Checkout
44+
uses: actions/checkout@v4
45+
46+
47+
# after checkout, you can checkout another repo, copy logo image or
48+
# other assets into '.docfx' folder to setup your own docfx environment.
49+
# note that images must be copied into '.docfx/images', 'images' or '.images'.
50+
51+
52+
###### main ######
53+
54+
- uses: sator-imaging/docfx-pages@v1
55+
id: deployment # required to show url in actions result page.
56+
with:
57+
58+
# required options
59+
# NOTE: double-quote (") cannot be used, backquote (`) must be escaped (\`).
60+
app_name: 'Lifecycle Manager'
61+
site_title: 'Lifecycle and Update Function Manager'
62+
site_footer: '© 2024 Sator Imaging'
63+
64+
# optional
65+
class_members: 'separatePages' # 'separatePages' or 'samePage'
66+
google_analytics: '' # empty to disable
67+
define_symbols: '' # additional preprocessor symbols separated by ';'
68+
69+
# paths must be relative from .docfx folder.
70+
# note that url works but only in top page. see sample website for detail.
71+
##site_logo: '<logo>.svg'
72+
##site_favicon: '<favicon>.svg'
73+
74+
# advanced options
75+
# --> https://dotnet.github.io/docfx/docs/template.html?tabs=modern#custom-template
76+
# main.js
77+
# NOTE: double-quote (") cannot be used, backquote (`) must be escaped (\`).
78+
main_js: |
79+
export default {
80+
defaultTheme: 'light',
81+
showLightbox: (img) => true,
82+
iconLinks: [
83+
{
84+
icon: 'github',
85+
href: 'https://github.com/sator-imaging',
86+
title: 'GitHub'
87+
},
88+
],
89+
}
90+
91+
# main.css
92+
# NOTE: double-quote (") cannot be used, backquote (`) must be escaped (\`).
93+
main_css: |

0 commit comments

Comments
 (0)