Skip to content

Enforce docs wiki publication in build-docs workflow - #2

Merged
MichaelWeissDEV merged 5 commits into
mainfrom
copilot/fix-failing-github-actions-job
Jun 5, 2026
Merged

Enforce docs wiki publication in build-docs workflow#2
MichaelWeissDEV merged 5 commits into
mainfrom
copilot/fix-failing-github-actions-job

Conversation

Copilot AI commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

build-docs could succeed without publishing docs, or fail late with an opaque wiki clone error. This change makes wiki publication an explicit requirement of the job and surfaces a clear failure when wiki sync is not possible.

  • Workflow contract hardening

    • Added an explicit wiki availability gate before sync.
    • The job now fails early if ${repo}.wiki.git is unreachable, instead of silently skipping publication.
  • Auth behavior

    • Wiki operations now use token fallback: secrets.WIKI_ACTION_TOKEN || github.token.
    • Keeps sync operable with repo-level token defaults while still honoring a dedicated wiki token when configured.
  • Wiki action wiring

    • Uses supported github-wiki-action@v4 inputs for path and commit message.
    • Sync step is now part of the required publish path rather than optional behavior.
- name: Verify wiki repository availability
  env:
    GH_TOKEN: ${{ secrets.WIKI_ACTION_TOKEN || github.token }}
  run: |
    if ! git ls-remote "https://x-access-token:${GH_TOKEN}@github.com/${{ github.repository }}.wiki.git" HEAD >/dev/null 2>&1; then
      echo "::error::GitHub wiki repository is unavailable. Enable the repository wiki and ensure token permissions allow wiki push."
      exit 1
    fi

- name: Sync Wiki
  uses: Andrew-Chen-Wang/github-wiki-action@v4
  with:
    token: ${{ secrets.WIKI_ACTION_TOKEN || github.token }}
    path: docs/api
    commit-message: "docs: update API documentation [skip ci]"

Copilot AI changed the title [WIP] Fix failing GitHub Actions job build-docs Harden docs workflow: skip wiki sync when wiki backend/token is unavailable Jun 5, 2026
Copilot AI requested a review from MichaelWeissDEV June 5, 2026 20:57
Copilot AI changed the title Harden docs workflow: skip wiki sync when wiki backend/token is unavailable Enforce docs wiki publication in build-docs workflow Jun 5, 2026
@MichaelWeissDEV
MichaelWeissDEV marked this pull request as ready for review June 5, 2026 21:32
@MichaelWeissDEV
MichaelWeissDEV merged commit 4ac1540 into main Jun 5, 2026
5 of 6 checks passed
@MichaelWeissDEV
MichaelWeissDEV deleted the copilot/fix-failing-github-actions-job branch June 5, 2026 21:32
MichaelWeissDEV added a commit that referenced this pull request Jun 18, 2026
…-actions-job

Enforce docs wiki publication in `build-docs` workflow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants