Skip to content

Merge branch 'dev' of https://github.com/BUTR/Bannerlord.ButterLib in… #381

Merge branch 'dev' of https://github.com/BUTR/Bannerlord.ButterLib in…

Merge branch 'dev' of https://github.com/BUTR/Bannerlord.ButterLib in… #381

Workflow file for this run

name: DocFX
on:
push:
branches:
#- master
# documentation will cover the dev branch for now
- dev
paths:
- '.github/workflows/docfx.yml'
- 'src/Bannerlord.ButterLib/**.cs'
- 'docs/**'
- 'README.md'
workflow_dispatch:
env:
# Disable the .NET logo in the console output.
DOTNET_NOLOGO: true
# Disable the .NET first time experience to skip caching NuGet packages and speed up the build.
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
# Disable sending .NET CLI telemetry to Microsoft.
DOTNET_CLI_TELEMETRY_OPTOUT: true
jobs:
docfx:
name: DocFX Documentation
runs-on: ubuntu-latest
steps:
- name: DocFX Setup
uses: butr/actions-docfx-setup@v4
with:
github-token: ${{secrets.GITHUB_TOKEN}}
- name: Build Bannerlord.ButterLib
run: dotnet build src/Bannerlord.ButterLib/Bannerlord.ButterLib.csproj;
shell: pwsh
- name: Run DocFX
run: >-
Copy-Item "README.md" -Destination "docs/index.md";
New-Item -Type dir "docs/images";
Copy-Item "resources/BUTR48.svg" -Destination "docs/images/BUTR48.svg";
docfx docs/docfx.json;
shell: pwsh
- name: Deploy DocFX
uses: crazy-max/ghaction-github-pages@v4
with:
target_branch: gh-pages
build_dir: docs/_site
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}