-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
swift: generate API docs as a DocC archive (#2335)
And include in GitHub release artifacts Updates rules_swift to pull in bazelbuild/rules_swift#838 When users open the archive, they'll have rich docs they can explore using Xcode's documentation navigator. When we update to Xcode 13.4, we'll be able to generate HTML docs with this approach and publish to the documentation website. Here's a demo of what that static site looks like: https://envoy-mobile-docc-demo.netlify.app/documentation/envoy/ https://user-images.githubusercontent.com/474794/171704142-993072a3-fbc2-4db6-9c70-65e9e1a47aac.mp4 Risk Level: Low Testing: Local, CI Docs Changes: Added Release Notes: Added Signed-off-by: JP Simard <jp@jpsim.com>
- Loading branch information
Showing
6 changed files
with
47 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ | |
*.pyc | ||
*.tulsiconf-user | ||
*.xcodeproj | ||
Envoy.doccarchive/ | ||
clang.bazelrc | ||
user.bazelrc | ||
tags | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -euo pipefail | ||
|
||
symbolgraph_dir="${1:-}" | ||
if [[ -z "$symbolgraph_dir" ]]; then | ||
./bazelw build //library/swift:ios_lib --config=release-ios --output_groups=+swift_symbol_graph | ||
symbolgraph_dir="bazel-bin/library/swift/ios_lib.symbolgraph" | ||
fi | ||
|
||
"$(xcrun --find docc)" convert \ | ||
--index \ | ||
--fallback-display-name Envoy \ | ||
--fallback-bundle-identifier io.envoyproxy.EnvoyMobile \ | ||
--fallback-bundle-version "$(cat VERSION)" \ | ||
--output-dir Envoy.doccarchive \ | ||
--additional-symbol-graph-dir "$symbolgraph_dir" |