diff --git a/.github/workflows/pr-check.yml b/.github/workflows/pr-check.yml index 30e2b23..c27a3dc 100644 --- a/.github/workflows/pr-check.yml +++ b/.github/workflows/pr-check.yml @@ -47,24 +47,6 @@ jobs: - name: Check dependency health run: python3 -m scripts.dependencies.check_package_health --solution ModularityKit.Mutator.slnx - docs: - name: docs - runs-on: ubuntu-latest - needs: build - - steps: - - uses: actions/checkout@v5 - - - uses: actions/setup-dotnet@v5 - with: - dotnet-version: 10.0.x - - - name: Install DocFX - run: dotnet tool update -g docfx - - - name: Build docs - run: docfx docfx.json - tests: name: ${{ matrix.name }} runs-on: ubuntu-latest @@ -195,7 +177,6 @@ jobs: needs: - build - dependency-health - - docs - tests - examples-core - examples-governance @@ -207,7 +188,6 @@ jobs: run: | echo "build: ${{ needs.build.result }}" echo "dependency-health: ${{ needs.dependency-health.result }}" - echo "docs: ${{ needs.docs.result }}" echo "tests: ${{ needs.tests.result }}" echo "examples-core: ${{ needs.examples-core.result }}" echo "examples-governance: ${{ needs.examples-governance.result }}" @@ -215,7 +195,6 @@ jobs: if [ "${{ needs.build.result }}" != "success" ] || \ [ "${{ needs.dependency-health.result }}" != "success" ] || \ - [ "${{ needs.docs.result }}" != "success" ] || \ [ "${{ needs.tests.result }}" != "success" ] || \ [ "${{ needs.examples-core.result }}" != "success" ] || \ [ "${{ needs.examples-governance.result }}" != "success" ] || \ diff --git a/.github/workflows/publish-docs.yml b/.github/workflows/publish-docs.yml new file mode 100644 index 0000000..fbca413 --- /dev/null +++ b/.github/workflows/publish-docs.yml @@ -0,0 +1,54 @@ +name: Publish Docs + +on: + push: + branches: [ main ] + workflow_dispatch: + +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: pages + cancel-in-progress: false + +jobs: + build: + name: build docs + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v5 + + - uses: actions/setup-dotnet@v5 + with: + dotnet-version: 10.0.x + + - name: Install DocFX + run: dotnet tool update -g docfx + + - name: Build docs + run: docfx docfx.json + + - name: Mark site as non-Jekyll + run: touch _site/.nojekyll + + - name: Upload docs site + uses: actions/upload-pages-artifact@v3 + with: + path: _site + + deploy: + name: deploy docs + runs-on: ubuntu-latest + needs: build + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/README.md b/README.md index fad327b..780453e 100644 --- a/README.md +++ b/README.md @@ -48,3 +48,7 @@ docfx docfx.json The generated site includes the conceptual docs under `Docs/` and the public API reference for the three published packages. + +The published site is deployed from `main` to GitHub Pages: + +https://modularitykit.github.io/ModularityKit.Mutator/