diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 00000000..8976b0fe --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,36 @@ +name: Docs + +on: + push: + branches: + - master + +permissions: + contents: write + +jobs: + deploy-docs: + runs-on: ubuntu-latest + env: + DOTNET_CLI_TELEMETRY_OPTOUT: 1 + + steps: + - name: Check out repository + uses: actions/checkout@v4 + + - name: Set up .NET 10 + uses: actions/setup-dotnet@v4 + with: + dotnet-version: 10.0.x + + - name: Install DocFX + run: dotnet tool install -g docfx + + - name: Build API docs + run: docfx docs/docfx.json + + - name: Deploy to gh-pages + uses: peaceiris/actions-gh-pages@v4 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/_site