Skip to content

CI: Build DocC catalog on every PR (#22)#32

Merged
itsniper merged 4 commits into
masterfrom
22-docc-ci
Jun 27, 2026
Merged

CI: Build DocC catalog on every PR (#22)#32
itsniper merged 4 commits into
masterfrom
22-docc-ci

Conversation

@itsniper

@itsniper itsniper commented Jun 27, 2026

Copy link
Copy Markdown
Member

Summary

Adds the first job to the CI pipeline scaffold: a DocC generation check that runs on every PR and push to master.

  • Runs swift package generate-documentation --target ReliaBLE --warnings-as-errors
  • Fails the build on broken DocC anchors or missing documented symbols
  • Uploads ReliaBLE.doccarchive.zip as a PR artifact for reviewer preview

This is the DocC sub-issue of #21 (full CI). Build/test/lint jobs will be added to the same workflow in a follow-up.

Also fixes a pre-existing DocC failure on master: the public Peripheral initializer doc comment linked to the internal PeripheralManager type.

How to preview docs from a PR

  1. Open the PR checks → DocC catalog job → Artifacts
  2. Download and unzip ReliaBLE.doccarchive.zip
  3. Open ReliaBLE.doccarchive in Xcode via File → Open Documentation Catalog, or use DocC preview

Closes #22

itsniper added 3 commits June 27, 2026 16:40
Add a partial GitHub Actions workflow with a DocC generation job that
runs on every PR and push to master. The check fails on documentation
warnings and uploads the rendered archive as a PR artifact.

Closes #22
The public Peripheral initializer doc comment referenced the internal
PeripheralManager type, causing generate-documentation to fail. Replace
the symbol link with plain prose so the new CI DocC check passes.
DocC output includes filenames with colons (e.g. operator docs) that
upload-artifact rejects on NTFS-safe paths. Zip the .doccarchive bundle
before uploading so PR reviewers can still download a preview.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds an initial GitHub Actions CI workflow job to validate DocC generation on every PR and on pushes to master, and adjusts a public API doc comment to avoid referencing an internal type that breaks DocC builds.

Changes:

  • Add a “DocC catalog” CI job that runs swift package generate-documentation --warnings-as-errors and uploads the generated .doccarchive as an artifact.
  • Update the Peripheral initializer doc comment to remove a DocC symbol link to an internal PeripheralManager type.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
Sources/ReliaBLE/Models/Peripheral.swift Updates a doc comment to avoid an invalid DocC link to an internal type.
.github/workflows/ci.yml Introduces a CI workflow job to build DocC docs and upload the archive as a PR artifact.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Sources/ReliaBLE/Models/Peripheral.swift Outdated
Comment thread .github/workflows/ci.yml Outdated
Comment thread .github/workflows/ci.yml Outdated
- Correct Peripheral init docs to point at discoveredPeripherals publisher
- Write DocC output to ./docc-output via --output-path instead of .build plugin path
- Add Xcode 16.4 existence check with installed-version diagnostics
- Ignore docc-output/ build directory
@itsniper itsniper merged commit f279449 into master Jun 27, 2026
1 check passed
@itsniper itsniper deleted the 22-docc-ci branch June 27, 2026 23:41
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.

CI: Build DocC catalog on every PR

2 participants