File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,16 @@ preview-docs:
99
1010# https://build-on-aws.github.io/swift-bedrock-library/documentation/bedrockservice/
1111generate-docs :
12+ # Dynamically add the swift-docc-plugin for doc generation
13+ cp Package.swift Package.swift.bak
14+ for manifest in Package.swift Package@* .swift ; do \
15+ if [[ -f " $$ manifest" ]] && ! grep -E -i " https://github.com/(apple|swiftlang)/swift-docc-plugin" " $$ manifest" ; then \
16+ echo " package.dependencies.append(" >> " $$ manifest" ; \
17+ echo " .package(url: \" https://github.com/swiftlang/swift-docc-plugin\" , from: \" 1.4.5\" )" >> " $$ manifest" ; \
18+ echo " )" >> " $$ manifest" ; \
19+ fi ; \
20+ done
21+
1222 touch .nojekyll
1323 swift package \
1424 --allow-writing-to-directory ./docs \
@@ -17,4 +27,6 @@ generate-docs:
1727 --disable-indexing \
1828 --transform-for-static-hosting \
1929 --hosting-base-path swift-bedrock-library \
20- --output-path ./docs
30+ --output-path ./docs
31+
32+ mv Package.swift.bak Package.swift
Original file line number Diff line number Diff line change @@ -15,7 +15,6 @@ let package = Package(
1515 . package ( url: " https://github.com/smithy-lang/smithy-swift " , from: " 0.158.0 " ) ,
1616 . package ( url: " https://github.com/apple/swift-log.git " , from: " 1.6.4 " ) ,
1717 . package ( url: " https://github.com/awslabs/aws-crt-swift " , from: " 0.53.0 " ) ,
18- . package ( url: " https://github.com/apple/swift-docc-plugin " , from: " 1.0.0 " ) ,
1918 ] ,
2019 targets: [
2120 . target(
You can’t perform that action at this time.
0 commit comments