Skip to content

Allow specifying additional arguments to pass to the docc check #99

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/scripts/check-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ done
log "Checking documentation targets..."
for target in $(yq -r '.builder.configs[].documentation_targets[]' .spi.yml); do
log "Checking target $target..."
swift package plugin generate-documentation --target "$target" --warnings-as-errors --analyze --level detailed
# shellcheck disable=SC2086 # We explicitly want to explode "$ADDITIONAL_DOCC_ARGUMENTS" into multiple arguments.
swift package plugin generate-documentation --target "$target" --warnings-as-errors --analyze --level detailed $ADDITIONAL_DOCC_ARGUMENTS
done

log "✅ Found no documentation issues."
6 changes: 6 additions & 0 deletions .github/workflows/soundness.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ on:
type: string
description: "Container image for the docs check job. Defaults to latest Swift Ubuntu image."
default: "swift:6.0-noble"
docs_check_additional_arguments:
type: string
description: "Additional arguments that should be passed to docc"
default: ""
unacceptable_language_check_enabled:
type: boolean
description: "Boolean to enable the acceptable language check job. Defaults to true."
Expand Down Expand Up @@ -123,6 +127,8 @@ jobs:
if: ${{ inputs.linux_pre_build_command }}
run: ${{ inputs.linux_pre_build_command }}
- name: Run documentation check
env:
ADDITIONAL_DOCC_ARGUMENTS: ${{ inputs.docs_check_additional_arguments }}
run: |
which curl yq || (apt -q update && apt -yq install curl yq)
curl -s https://raw.githubusercontent.com/swiftlang/github-workflows/refs/heads/main/.github/workflows/scripts/check-docs.sh | bash
Expand Down