update page CI
This commit is contained in:
parent
d29ac655db
commit
00b067c60a
52
.github/workflows/page.yml
vendored
Normal file
52
.github/workflows/page.yml
vendored
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
# Simple workflow for deploying static content to GitHub Pages
|
||||||
|
name: Deploy static content to Pages
|
||||||
|
|
||||||
|
on:
|
||||||
|
# Runs on pushes targeting the default branch
|
||||||
|
push:
|
||||||
|
branches: ["main"]
|
||||||
|
|
||||||
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
pages: write
|
||||||
|
id-token: write
|
||||||
|
|
||||||
|
# Allow one concurrent deployment
|
||||||
|
concurrency:
|
||||||
|
group: "pages"
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
# Single deploy job since we're just deploying
|
||||||
|
deploy:
|
||||||
|
environment:
|
||||||
|
name: github-pages
|
||||||
|
url: ${{ steps.deployment.outputs.page_url }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Setup Pages
|
||||||
|
uses: actions/configure-pages@v2
|
||||||
|
|
||||||
|
- name: install mdbook
|
||||||
|
uses: extractions/setup-mdbook@v1
|
||||||
|
|
||||||
|
- name: build mdbook
|
||||||
|
shell: pwsh
|
||||||
|
run: mdbook build ./docs/page
|
||||||
|
|
||||||
|
- name: Upload artifact
|
||||||
|
uses: actions/upload-pages-artifact@v1
|
||||||
|
with:
|
||||||
|
|
||||||
|
# Upload entire repository
|
||||||
|
path: './docs/page/docs'
|
||||||
|
- name: Deploy to GitHub Pages
|
||||||
|
id: deployment
|
||||||
|
uses: actions/deploy-pages@v1
|
@ -13,8 +13,19 @@ extra-watch-dirs = [] # directories to watch for triggering builds
|
|||||||
|
|
||||||
[output.html]
|
[output.html]
|
||||||
input-404 = "404.md"
|
input-404 = "404.md"
|
||||||
|
additional-css = ["open-in.css"]
|
||||||
# cname = 'hws.shenjack.top'
|
# cname = 'hws.shenjack.top'
|
||||||
|
|
||||||
|
# Required: Your repository URL used in the link.
|
||||||
|
git-repository-url = "https://github.com/shenjackyuanjie/Difficult-Rocket"
|
||||||
|
|
||||||
|
# Your git branch. Defaults to `main`
|
||||||
|
git-branch = "main"
|
||||||
|
|
||||||
|
# The text to use in the footer.
|
||||||
|
# The link text is marked by `[]`
|
||||||
|
open-on-text = "Found a bug? [Edit this page on GitHub.]"
|
||||||
|
|
||||||
[output.html.search]
|
[output.html.search]
|
||||||
limit-results = 15
|
limit-results = 15
|
||||||
|
|
||||||
@ -22,6 +33,10 @@ limit-results = 15
|
|||||||
enable = true # include support for printable output
|
enable = true # include support for printable output
|
||||||
page-break = true # insert page-break after each chapter
|
page-break = true # insert page-break after each chapter
|
||||||
|
|
||||||
|
[preprocessor.open-on-gh]
|
||||||
|
command = "mdbook-open-on-gh"
|
||||||
|
renderer = ["html"]
|
||||||
|
|
||||||
# [output.copy-resources]
|
# [output.copy-resources]
|
||||||
# optional = true
|
# optional = true
|
||||||
# command = 'python output.py'
|
# command = 'python output.py'
|
||||||
|
Loading…
Reference in New Issue
Block a user