Skip to content

Commit 246da05

Browse files
authored
Fix doc generation and jazzy version (#15)
Motivation: The combination of Ruby and Jazzy are throwing up issues in CI on older Ubuntu versions. Modifications: - Only install Jazzy on focal - Fix doc generation script to use more recent source-kitten syntax Results: - CI doesn't complain - Docs get built
1 parent 92e9a35 commit 246da05

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

docker/Dockerfile

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,10 @@ ENV LANGUAGE en_US.UTF-8
1616
RUN apt-get update && apt-get install -y wget
1717
RUN apt-get update && apt-get install -y lsof dnsutils netcat-openbsd net-tools curl jq # used by integration tests
1818

19-
# ruby and jazzy for docs generation
19+
# ruby and jazzy for docs generation, only on focal
2020
RUN apt-get update && apt-get install -y ruby ruby-dev libsqlite3-dev build-essential
21-
# switch off gem docs building
22-
RUN echo "gem: --no-document" > ~/.gemrc
23-
# jazzy no longer works on xenial as ruby is too old.
24-
RUN if [ "${ubuntu_version}" != "xenial" ] ; then gem install jazzy; fi
21+
RUN if [ "${ubuntu_version}" = "focal" ] ; then echo "gem: --no-document" > ~/.gemrc; fi
22+
RUN if [ "${ubuntu_version}" == "focal" ] ; then gem install jazzy; fi
2523

2624
# tools
2725
RUN mkdir -p $HOME/.tools

scripts/generate_docs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ if [[ "$(uname -s)" == "Linux" ]]; then
3939
# generate
4040
for module in "${modules[@]}"; do
4141
if [[ ! -f "$root_path/.build/sourcekitten/$module.json" ]]; then
42-
"$source_kitten_path/sourcekitten" doc --spm-module $module > "$root_path/.build/sourcekitten/$module.json"
42+
"$source_kitten_path/sourcekitten" doc --module-name $module > "$root_path/.build/sourcekitten/$module.json"
4343
fi
4444
done
4545
fi

0 commit comments

Comments
 (0)