Skip to content

Commit

Permalink
Merge pull request #356 from typelevel/apiURL-fallback
Browse files Browse the repository at this point in the history
Fallback to apiURL if javadocioUrl does not exist
  • Loading branch information
armanbilge authored Aug 14, 2022
2 parents d8a628f + 89baeb7 commit 25c24d6
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,12 @@ object TypelevelSitePlugin extends AutoPlugin {
val p = tlSiteApiPackage.value.fold("")(_.replace('.', '/') + "/index.html")
url(s"https://www.javadoc.io/doc/$o/$n/$v/$p")
}
lazy val fallbackUrl = for {
moduleId <- (ThisProject / tlSiteApiModule).value
apiURL <- moduleId.extraAttributes.get("e:info.apiURL")
} yield url(apiURL)

tlSiteApiUrl.value.orElse(javadocioUrl)
tlSiteApiUrl.value.orElse(javadocioUrl).orElse(fallbackUrl)
},
tlSiteHeliumConfig := {
Helium
Expand Down

0 comments on commit 25c24d6

Please sign in to comment.