Skip to content
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
24 changes: 14 additions & 10 deletions .github/workflows/api-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ jobs:
printf "\norg.gradle.jvmargs=-Xmx6g -XX:MaxPermSize=6g" >> gradle.properties

./gradlew dokkaHtmlMultiModule
mkdir smithy-kotlin-docs
mv build/dokka/htmlMultiModule/* smithy-kotlin-docs/
mkdir smithy-kotlin
mv build/dokka/htmlMultiModule/* smithy-kotlin/
- name: Upload Smithy-Kotlin Doc Artifact
uses: actions/upload-artifact@v2
with:
name: smithy-kotlin-docs
path: smithy-kotlin/smithy-kotlin-docs
name: smithy-kotlin
path: smithy-kotlin/smithy-kotlin

api-doc-gen-parallel:
runs-on: ubuntu-latest
Expand All @@ -72,8 +72,8 @@ jobs:
- name: Download smithy-kotlin artifacts
uses: actions/download-artifact@v2
with:
name: smithy-kotlin-docs
path: smithy-kotlin-docs
name: smithy-kotlin
path: smithy-kotlin
- name: Generate API Docs
id: gen-docs
run: |
Expand All @@ -87,7 +87,7 @@ jobs:
shopt -s nullglob

# configure path to smithy-kotlin's package-list
smithy_kotlin_package_list_path="$(pwd)/smithy-kotlin-docs/package-list"
smithy_kotlin_package_list_path="$(pwd)/smithy-kotlin/package-list"

# Track if docs were generated in this segment of job run.
docs_generated=false
Expand All @@ -111,7 +111,11 @@ jobs:
n=0
until [ "$n" -ge 5 ]
do
./gradlew --no-parallel -PdokkaOutSubDir=$SERVICE_NAME -PsmithyKotlinPackageListUrl=file://$smithy_kotlin_package_list_path dokkaHtmlMultiModule && break
./gradlew --no-parallel -PdokkaOutSubDir=$SERVICE_NAME \
-PsmithyKotlinDocBaseUrl=https://docs.aws.amazon.com/sdk-for-kotlin/latest/reference/smithy-kotlin \
-PsmithyKotlinPackageListUrl=file://$smithy_kotlin_package_list_path \
dokkaHtmlMultiModule && break

n=$((n+1))
sleep 15
done
Expand Down Expand Up @@ -159,7 +163,7 @@ jobs:
done
- name: Add smithy-kotlin docs
run: |
mv smithy-kotlin-docs target/
mv smithy-kotlin target/
- name: Generate Top Level Index
run: |
INDEX_FILE=target/index.html
Expand Down Expand Up @@ -194,7 +198,7 @@ jobs:
# Generate list of services
for aws_service_dir in target/*
do
if [[ "$aws_service_dir" != "target/index.html" && "$aws_service_dir" != "target/smithy-kotlin-docs" ]]; then # no self reference
if [[ "$aws_service_dir" != "target/index.html" && "$aws_service_dir" != "target/smithy-kotlin" ]]; then # no self reference
SERVICE_NAME=${aws_service_dir##*/} # Extract the filename from the path

echo " <div class='table-row'>" >> $INDEX_FILE
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,6 @@ mockkVersion=1.12.0
# logging - JVM
slf4jVersion=1.7.30

# dokka config
# dokka config (values specified at build-time as needed)
smithyKotlinPackageListUrl=
smithyKotlinDocBaseUrl=https://docs.aws.amazon.com/sdk-for-kotlin/latest/reference/smithy-kotlin-docs
smithyKotlinDocBaseUrl=