Commit 3b01f353 authored by Joshua Lock's avatar Joshua Lock Committed by Dr. Matthias St. Pierre
Browse files

Add a check for history section location to find-doc-nits



Check that the HISTORY section is located after the SEE ALSO section,
this is a much more frequent order in OpenSSL manual pages (and UNIX
manual pages in general).

Also check that SEE ALSO comes after EXAMPLES, so that the tool can
ensure the correct manual section sequence.

Reviewed-by: default avatarMatthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Reviewed-by: default avatarRichard Levitte <levitte@openssl.org>

(cherry picked from commit 573ac8f2)

Reviewed-by: default avatarMatt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/8736)
parent 32a775df
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -166,6 +166,10 @@ sub check()

    # Check if EXAMPLES is located after RETURN VALUES section.
    &check_section_location($filename, $contents, "RETURN VALUES", "EXAMPLES") if $filename =~ m|man3/|;
    # Check if HISTORY is located after SEE ALSO
    &check_section_location($filename, $contents, "SEE ALSO", "HISTORY") if $filename =~ m|man3/|;
    # Check if SEE ALSO is located after EXAMPLES
    &check_section_location($filename, $contents, "EXAMPLES", "SEE ALSO") if $filename =~ m|man3/|;

    my $id = "${filename}:1:";