Skip to content

Commit 93cb710

Browse files
Bump version to 1.24.0
2 parents 8b042ac + 37d57e4 commit 93cb710

18 files changed

+433
-145
lines changed

CHANGELOG

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
CHANGELOG
22
`````````
33

4+
Version 1.24.0 -- 2022-04-14
5+
----------------------------
6+
- Do not create HTML docs of Litani man pages if a flag is specified
7+
Running `doc/configure` with `--no-html` allows one
8+
to ultimately build only the man equivalent of the
9+
Litani documentation.
10+
11+
- License documentation under CC-BY-SA 4.0
12+
13+
- Fix changelog
14+
15+
416
Version 1.23.0 -- 2022-04-11
517
----------------------------
6-
Summary=======
18+
Summary
19+
=======
720

821
- Add get-jobs and set-jobs subcommands
922

doc/LICENSE

Lines changed: 350 additions & 0 deletions
Large diffs are not rendered by default.

doc/README

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
The documentation is made available under the Creative Commons
2+
Attribution-ShareAlike 4.0 International License. See the LICENSE file.

doc/configure

Lines changed: 42 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@
1414
# permissions and limitations under the License.
1515

1616

17-
import sys
17+
import argparse
1818
import pathlib
19+
import sys
1920

2021

2122
DOC_DIR = pathlib.Path(sys.path[0]).resolve()
@@ -89,6 +90,19 @@ RULES = [{
8990
}]
9091

9192

93+
def get_args():
94+
pars = argparse.ArgumentParser(description="Build documentation for Litani")
95+
for arg in [{
96+
"flags": ["--no-html"],
97+
"action": "store_false",
98+
"help": "Do not build a version of the documentation in HTML",
99+
"dest": "gen_html",
100+
}]:
101+
flags = arg.pop("flags")
102+
pars.add_argument(*flags, **arg)
103+
return pars.parse_args()
104+
105+
92106
def make_html_unique(man_name, html_man, html_mans, builds):
93107
html_unique = HTML_UNIQUE_DIR / f"{man_name}.html"
94108
builds.append({
@@ -118,7 +132,7 @@ def man_to_html(man_name, man_out, builds):
118132

119133

120134
def convert_man_dir_to_man(
121-
src_dir, dst_dir, rule, html_mans, builds, extra_inputs=None):
135+
src_dir, dst_dir, rule, html_mans, builds, gen_html, extra_inputs=None):
122136
for man in (src_dir).iterdir():
123137
man_name = str(man.name).split(".", 1)[0]
124138
if man.suffix == ".scdoc":
@@ -140,11 +154,12 @@ def convert_man_dir_to_man(
140154
"data-path": man.resolve(),
141155
}
142156
})
143-
html_man = man_to_html(man_name, man_out, builds)
144-
make_html_unique(man_name, html_man, html_mans, builds)
157+
if gen_html:
158+
html_man = man_to_html(man_name, man_out, builds)
159+
make_html_unique(man_name, html_man, html_mans, builds)
145160

146161

147-
def add_litani_7(builds, html_mans):
162+
def add_litani_7(builds, html_mans, gen_html):
148163
"""The litani(7) man page is special because it contains a table of contents
149164
of the other pages, so it depends on the others."""
150165

@@ -171,34 +186,39 @@ def add_litani_7(builds, html_mans):
171186
"outputs": [man_out],
172187
"rule": "sc_to_man",
173188
}])
174-
html_man = man_to_html("litani.7", man_out, builds)
175-
make_html_unique("litani.7", html_man, html_mans, builds)
189+
if gen_html:
190+
html_man = man_to_html("litani.7", man_out, builds)
191+
make_html_unique("litani.7", html_man, html_mans, builds)
176192

177193

178194
def main():
195+
args = get_args()
179196
builds = []
180197
html_mans = []
181198

182199
convert_man_dir_to_man(
183-
SRC_DIR / "man", MAN_DIR, "sc_to_man", html_mans, builds)
200+
SRC_DIR / "man", MAN_DIR, "sc_to_man", html_mans, builds,
201+
args.gen_html)
184202
convert_man_dir_to_man(
185203
SRC_DIR / "voluptuous-man", MAN_DIR, "voluptuous_to_man", html_mans,
186-
builds, extra_inputs=[TEMPLATE_DIR / "voluptuous-man.jinja.scdoc"])
204+
builds, args.gen_html,
205+
extra_inputs=[TEMPLATE_DIR / "voluptuous-man.jinja.scdoc"])
187206

188-
add_litani_7(builds, html_mans)
207+
add_litani_7(builds, html_mans, args.gen_html)
189208

190-
builds.append({
191-
"inputs": html_mans + [
192-
BIN_DIR / "build-html-doc",
193-
TEMPLATE_DIR / "index.jinja.html",
194-
],
195-
"outputs": [DOC_DIR / "out" / "html"/ "index.html"],
196-
"rule": "build_html_doc",
197-
"variables": {
198-
"html-mans": " ".join([str(h) for h in html_mans]),
199-
"man-html-dir": HTML_MAN_SRC_DIR,
200-
}
201-
})
209+
if args.gen_html:
210+
builds.append({
211+
"inputs": html_mans + [
212+
BIN_DIR / "build-html-doc",
213+
TEMPLATE_DIR / "index.jinja.html",
214+
],
215+
"outputs": [DOC_DIR / "out" / "html"/ "index.html"],
216+
"rule": "build_html_doc",
217+
"variables": {
218+
"html-mans": " ".join([str(h) for h in html_mans]),
219+
"man-html-dir": HTML_MAN_SRC_DIR,
220+
}
221+
})
202222

203223
for build in builds:
204224
for k, v in build.items():

doc/src/litani7/litani.jinja.scdoc

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani(7) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
Litani allows you to build up a graph of commands to execute in
@@ -70,6 +60,13 @@ _https://awslabs.github.io/aws-build-accumulator/_:
7060
{%- endfor -%}
7161
{% endif %}{% endfor %}
7262

63+
# COPYING
64+
65+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. Litani's
66+
source code is licensed under the Apache License 2.0, and the manual pages are
67+
licensed under CC-BY-SA 4.0. See the LICENSE files for details.
68+
69+
7370
# SEE ALSO
7471

7572
- *ninja(1)*, which Litani uses to actually run the build: _https://ninja-build.org_

doc/src/man/litani-acquire-html-dir.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-acquire-html-dir(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-add-job.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-add-job(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-dump-run.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-dump-run(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-get-jobs.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-get-jobs(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-init.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-init(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-print-html-dir.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-print-html-dir(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-release-html-dir.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-release-html-dir(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-run-build.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-run-build(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-set-jobs.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-set-jobs(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/man/litani-transform-jobs.scdoc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,7 @@
11
litani-transform-jobs(1) "" "Litani Build System"
22

33
; Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
4-
5-
; Licensed under the Apache License, Version 2.0 (the "License").
6-
; You may not use this file except in compliance with the License.
7-
; A copy of the License is located at
8-
9-
; http://www.apache.org/licenses/LICENSE-2.0
10-
11-
; or in the "license" file accompanying this file. This file is distributed
12-
; on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13-
; express or implied. See the License for the specific language governing
14-
; permissions and limitations under the License.
4+
; SPDX-License-Identifier: CC-BY-SA-4.0
155

166

177
# NAME

doc/src/voluptuous-man/litani-outcome-table.json.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2+
# SPDX-License-Identifier: CC-BY-SA-4.0
3+
14
header: >
25
# NAME
36

doc/src/voluptuous-man/litani-run.json.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2+
# SPDX-License-Identifier: CC-BY-SA-4.0
3+
14
header: >
25
# NAME
36

lib/litani.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
TIME_FORMAT_W = "%Y-%m-%dT%H:%M:%SZ"
3434
TIME_FORMAT_MS = "%Y-%m-%dT%H:%M:%S.%fZ"
3535
VERSION_MAJOR = 1
36-
VERSION_MINOR = 23
36+
VERSION_MINOR = 24
3737
VERSION_PATCH = 0
3838
RC = False
3939

0 commit comments

Comments
 (0)