]> git.ipfire.org Git - thirdparty/git.git/blame - ci/test-documentation.sh
Merge branch 'am/mailmap-andrey-mazo'
[thirdparty/git.git] / ci / test-documentation.sh
CommitLineData
505ad913 1#!/usr/bin/env bash
b98712b9
LS
2#
3# Perform sanity checks on documentation and build it.
4#
5
c2160f2d 6. ${0%/*}/lib.sh
657343a6 7
37fc8cb1
SG
8filter_log () {
9 sed -e '/^GIT_VERSION = /d' \
10 -e '/^ \* new asciidoc flags$/d' \
11 "$1"
12}
13
b98712b9
LS
14make check-builtins
15make check-docs
b98712b9 16
159e6010 17# Build docs with AsciiDoc
37fc8cb1
SG
18make doc > >(tee stdout.log) 2> >(tee stderr.raw >&2)
19cat stderr.raw
20filter_log stderr.raw >stderr.log
21test ! -s stderr.log
b98712b9
LS
22test -s Documentation/git.html
23test -s Documentation/git.xml
24test -s Documentation/git.1
159e6010
LS
25grep '<meta name="generator" content="AsciiDoc ' Documentation/git.html
26
37fc8cb1 27rm -f stdout.log stderr.log stderr.raw
b92cb86e
SG
28check_unignored_build_artifacts
29
159e6010
LS
30# Build docs with AsciiDoctor
31make clean
37fc8cb1
SG
32make USE_ASCIIDOCTOR=1 doc > >(tee stdout.log) 2> >(tee stderr.raw >&2)
33cat stderr.raw
34filter_log stderr.raw >stderr.log
35test ! -s stderr.log
159e6010
LS
36test -s Documentation/git.html
37grep '<meta name="generator" content="Asciidoctor ' Documentation/git.html
9cc2c76f 38
37fc8cb1 39rm -f stdout.log stderr.log stderr.raw
b92cb86e
SG
40check_unignored_build_artifacts
41
9cc2c76f 42save_good_tree