Skip to content

Commit 3b5faf0

Browse files
committed
Merge branch '45-api-docs' into 'master'
45 -- Add API Documentation See merge request Mordil/swift-redis-nio-client!48
2 parents 6f6fe74 + dd839fd commit 3b5faf0

20 files changed

+2762
-3
lines changed

.gitlab-ci.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,28 @@ pages:
88
only:
99
- tags
1010
tags:
11-
- private-xcode
12-
script:
13-
- "echo 'TODO #45 -- Publish API Docs'"
11+
- private-macOS
12+
script: |
13+
version=$(git describe --abbrev=0 --tags || echo "0.0.0")
14+
swift build
15+
sourcekitten doc --spm-module "RedisNIO" > ./RedisNIO.json
16+
swift package generate-xcodeproj
17+
jazzy --clean \
18+
--author "Nathan Harris (Mordil)" \
19+
--readme "./README.md" \
20+
--author_url "https://mordil.info" \
21+
--github_url "https://gitlab.com/mordil/swift-redis-nio-client" \
22+
--github-file-prefix https://gitlab.com/mordil/swift-redis-nio-client/blob/$version \
23+
--root-url "https://mordil.gitlab.io/swift-redis-nio-client/docs/RedisNIO" \
24+
--module "RedisNIO" \
25+
--module-version "$version" \
26+
--theme fullwidth \
27+
--xcodebuild-arguments -scheme,swift-redis-nio-client-Package \
28+
--sourcekitten-sourcefile "./RedisNIO.json" \
29+
--output "./public"
30+
artifacts:
31+
paths:
32+
- public
1433

1534
.build:
1635
stage: build release
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
/* Credit to https://gist.github.com/wataru420/2048287 */
2+
3+
.highlight {
4+
.c { color: #999988; font-style: italic } /* Comment */
5+
.err { color: #a61717; background-color: #e3d2d2 } /* Error */
6+
.k { color: #000000; font-weight: bold } /* Keyword */
7+
.o { color: #000000; font-weight: bold } /* Operator */
8+
.cm { color: #999988; font-style: italic } /* Comment.Multiline */
9+
.cp { color: #999999; font-weight: bold } /* Comment.Preproc */
10+
.c1 { color: #999988; font-style: italic } /* Comment.Single */
11+
.cs { color: #999999; font-weight: bold; font-style: italic } /* Comment.Special */
12+
.gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
13+
.gd .x { color: #000000; background-color: #ffaaaa } /* Generic.Deleted.Specific */
14+
.ge { color: #000000; font-style: italic } /* Generic.Emph */
15+
.gr { color: #aa0000 } /* Generic.Error */
16+
.gh { color: #999999 } /* Generic.Heading */
17+
.gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
18+
.gi .x { color: #000000; background-color: #aaffaa } /* Generic.Inserted.Specific */
19+
.go { color: #888888 } /* Generic.Output */
20+
.gp { color: #555555 } /* Generic.Prompt */
21+
.gs { font-weight: bold } /* Generic.Strong */
22+
.gu { color: #aaaaaa } /* Generic.Subheading */
23+
.gt { color: #aa0000 } /* Generic.Traceback */
24+
.kc { color: #000000; font-weight: bold } /* Keyword.Constant */
25+
.kd { color: #000000; font-weight: bold } /* Keyword.Declaration */
26+
.kp { color: #000000; font-weight: bold } /* Keyword.Pseudo */
27+
.kr { color: #000000; font-weight: bold } /* Keyword.Reserved */
28+
.kt { color: #445588; } /* Keyword.Type */
29+
.m { color: #009999 } /* Literal.Number */
30+
.s { color: #d14 } /* Literal.String */
31+
.na { color: #008080 } /* Name.Attribute */
32+
.nb { color: #0086B3 } /* Name.Builtin */
33+
.nc { color: #445588; font-weight: bold } /* Name.Class */
34+
.no { color: #008080 } /* Name.Constant */
35+
.ni { color: #800080 } /* Name.Entity */
36+
.ne { color: #990000; font-weight: bold } /* Name.Exception */
37+
.nf { color: #990000; } /* Name.Function */
38+
.nn { color: #555555 } /* Name.Namespace */
39+
.nt { color: #000080 } /* Name.Tag */
40+
.nv { color: #008080 } /* Name.Variable */
41+
.ow { color: #000000; font-weight: bold } /* Operator.Word */
42+
.w { color: #bbbbbb } /* Text.Whitespace */
43+
.mf { color: #009999 } /* Literal.Number.Float */
44+
.mh { color: #009999 } /* Literal.Number.Hex */
45+
.mi { color: #009999 } /* Literal.Number.Integer */
46+
.mo { color: #009999 } /* Literal.Number.Oct */
47+
.sb { color: #d14 } /* Literal.String.Backtick */
48+
.sc { color: #d14 } /* Literal.String.Char */
49+
.sd { color: #d14 } /* Literal.String.Doc */
50+
.s2 { color: #d14 } /* Literal.String.Double */
51+
.se { color: #d14 } /* Literal.String.Escape */
52+
.sh { color: #d14 } /* Literal.String.Heredoc */
53+
.si { color: #d14 } /* Literal.String.Interpol */
54+
.sx { color: #d14 } /* Literal.String.Other */
55+
.sr { color: #009926 } /* Literal.String.Regex */
56+
.s1 { color: #d14 } /* Literal.String.Single */
57+
.ss { color: #990073 } /* Literal.String.Symbol */
58+
.bp { color: #999999 } /* Name.Builtin.Pseudo */
59+
.vc { color: #008080 } /* Name.Variable.Class */
60+
.vg { color: #008080 } /* Name.Variable.Global */
61+
.vi { color: #008080 } /* Name.Variable.Instance */
62+
.il { color: #009999 } /* Literal.Number.Integer.Long */
63+
}

0 commit comments

Comments
 (0)