Skip to content

Commit cb043c2

Browse files
authored
[Docs] Only check the specific module during docc verification (#4)
[Docs] Only check the specific module during docc verification ## Summary Only verify the provided product instead of checking them all, which would include dependencies. ## Test Plan Ran soundness locally and verified it still works. Reviewed by: simonjbeaumont Builds: ✔︎ pull request validation (5.8) - Build finished. ✔︎ pull request validation (5.9) - Build finished. ✔︎ pull request validation (nightly) - Build finished. ✔︎ pull request validation (soundness) - Build finished. #4
1 parent 34a1118 commit cb043c2

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

scripts/check-for-docc-warnings.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,14 @@ log() { printf -- "** %s\n" "$*" >&2; }
1919
error() { printf -- "** ERROR: %s\n" "$*" >&2; }
2020
fatal() { error "$@"; exit 1; }
2121

22+
log "Checking required environment variables..."
23+
test -n "${DOCC_TARGET:-}" || fatal "DOCC_TARGET unset"
24+
2225
CURRENT_SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
2326
REPO_ROOT="$(git -C "${CURRENT_SCRIPT_DIR}" rev-parse --show-toplevel)"
2427

2528
swift package --package-path "${REPO_ROOT}" plugin generate-documentation \
29+
--product "${DOCC_TARGET}" \
2630
--analyze \
2731
--level detailed \
2832
--warnings-as-errors \

scripts/soundness.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ fatal() { error "$@"; exit 1; }
2020

2121
CURRENT_SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
2222
NUM_CHECKS_FAILED=0
23+
export DOCC_TARGET=OpenAPIRuntime
2324

2425
SCRIPT_PATHS=(
2526
"${CURRENT_SCRIPT_DIR}/check-for-broken-symlinks.sh"

0 commit comments

Comments
 (0)