From 1db8927ee17215f9ba578eb387a4b6f94a68b9ad Mon Sep 17 00:00:00 2001 From: Jaesung Date: Sat, 4 Nov 2023 18:31:39 +0900 Subject: [PATCH] Update GENERATE_DOCS.sh --- GENERATE_DOCS.sh | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/GENERATE_DOCS.sh b/GENERATE_DOCS.sh index 6375e7d..791831e 100755 --- a/GENERATE_DOCS.sh +++ b/GENERATE_DOCS.sh @@ -1,13 +1,32 @@ set -e -# 사전 정의 -OUTPUT_DIRECTORY_PATH="./docs" +# 사전 정의 (Definition) +OUTPUT_PATH="./docs" TARGET_NAME="PackageDocCExample" HOSTING_BASE_PATH="package-docc-example" +# for `xcodebuild docbuild` +# BUILD_DESTINATION="generic/platform=iOS" +# BUILD_PATH="/tmp/docbuild" +# DOCCARCHIVE_PATH="${BUILD_PATH}/Build/Products/Debug-iphoneos/${TARGET_NAME}.doccarchive" -# 문서 빌드 -swift package --allow-writing-to-directory ${OUTPUT_DIRECTORY_PATH} \ +# --------------------- +# docc-plugin +# ---------------------- +swift package --allow-writing-to-directory ${OUTPUT_PATH} \ generate-documentation --target ${TARGET_NAME} --disable-indexing \ - --output-path ${OUTPUT_DIRECTORY_PATH} \ + --output-path ${OUTPUT_PATH} \ --transform-for-static-hosting \ --hosting-base-path ${HOSTING_BASE_PATH} + +# --------------------- +# xcodebuild +# ---------------------- +# xcodebuild docbuild \ +# -scheme ${TARGET_NAME} \ +# -destination ${BUILD_DESTINATION} \ +# -derivedDataPath ${BUILD_PATH} +# +# $(xcrun --find docc) process-archive \ +# transform-for-static-hosting ${DOCCARCHIVE_PATH} \ +# --hosting-base-path ${HOSTING_BASE_PATH} \ +# --output-path ${OUTPUT_PATH}