Manual Page Scan example
#################################
In order to improve usability of packages in Fedora, project Man Page Scan was created and its task is to provide consistency of man pages (and documentation in general).
How to use
----------
To run `man-page-day.sh`
```
$ man-page-day.sh $component
```
Error/warning explanation
----------
Here are some examples:
Warnings
----------
1) man page is in section 8. Only commands requiring admin privileges, or daemons should be in this section, the rest should be in section 1
The manual is generally split into eight numbered sections and in section 8 should be system administration commands and daemons.
2) these ($manfilesleft) man pages left unassigned:
Check whether we used all man pages.
Duplicate manfiles array, so we know, which man pages was "unused"
```
manfilesleft=("${manfiles[@]}")
```
Then
1. Check if bin files has man pages
2. Check if config files has man pages
So script is removing "used" man page after these iterations and checks if `$manfilesleft -eq 0`.
3) repeated words in man page: $words
Check for repeated words in one line.
Errors
----------
1) binary $binary has no man page!
Checking whether binary files have man pages.
2) config file $file has no man page! Check it's content for proper documentation
Check if config files has man pages.
3) man page is in unexpected section 8. Man pages for configuration files should be in section5
The manual is generally split into eight numbered sections and in section 5 should be file formats and conventions.
4) man page parsing with lexgrog failed. See lexgrog(1) for more info
lexgrog - parse header information in man pages.
exit status 2 - lexgrog failed to parse one or more of its input files.
5) man page is in unexpected section ${sec}. Man pages for binaries should be in section 1, orif binary requires admin privileges or if binary is a daemon, then the man page should be in section 8.
So, it's something else (not sections 1 and 8).