mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-26 15:57:56 +01:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
54 lines
1.4 KiB
YAML
54 lines
1.4 KiB
YAML
name: Build and publish API docs
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
generate-docs:
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup .NET Core
|
|
uses: actions/setup-dotnet@v3.0.3
|
|
with:
|
|
dotnet-version: 6.0.100
|
|
|
|
- name: Setup DocFX
|
|
uses: crazy-max/ghaction-chocolatey@v2
|
|
with:
|
|
args: install docfx
|
|
|
|
- name: Install dependencies
|
|
run: dotnet restore
|
|
|
|
- name: DocFX Build
|
|
working-directory: docfx
|
|
# https://stackoverflow.com/questions/56726429/how-to-run-multiple-commands-in-one-github-actions-docker
|
|
run: |
|
|
rm ../docs -Recurse -Force -ErrorAction SilentlyContinue
|
|
docfx docfx.json
|
|
continue-on-error: false
|
|
|
|
- name: Publish
|
|
if: github.event_name == 'push'
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
with:
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
publish_dir: docs
|
|
force_orphan: true
|
|
|
|
# - name: Use docfx to build API Docs
|
|
# uses: nikeee/docfx-action@v1.0.0
|
|
# with:
|
|
# args: docfx/docfx.json
|
|
|
|
# # Publish generated site using GitHub Pages
|
|
# - uses: maxheld83/ghpages@master
|
|
# name: Publish API Documentation on GitHub Pages
|
|
# env:
|
|
# BUILD_DIR: docs # docfx's default output directory is _site
|
|
# GH_PAT: ${{ secrets.GH_PAT }} # See https://github.com/maxheld83/ghpages |