Skip to content

Commit

Permalink
Run mandoc lint checker on man pages (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
dharple committed Feb 15, 2021
1 parent 9957ee3 commit c596970
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 17 deletions.
21 changes: 17 additions & 4 deletions BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,26 @@ Installation that overwrites config files and translation tables:

Install `mandoc` to generate fresh PDFs.

## Formatting

Check code:

```
astyle --style=kr --indent-switches --add-braces --pad-oper --pad-header $(ls src/*.[ch] | egrep -v 'config_file_(lex|yacc)')`
```

Check docs:

```
mandoc -T lint man/*.[15]
```

## Testing

1. Run static analysis tools. (sparse, cppcheck)
2. Run `astyle --style=kr --indent-switches --add-braces --pad-oper --pad-header $(ls src/*.[ch] | egrep -v 'config_file_(lex|yacc)')`
3. Run `make clean ; make` to rebuild `detox`.
4. Run `tests/test.sh src/detox` to perform basic regression tests.
5. Run custom external regression tests.
2. Run `make clean ; make` to rebuild `detox`.
3. Run `tests/test.sh src/detox` to perform basic regression tests.
4. Run custom external regression tests.

## Release

Expand Down
4 changes: 2 additions & 2 deletions man/detox.1
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,12 @@ showing their filters and options.
.El
.Sh SEE ALSO
.Xr inline-detox 1 ,
.Xr detoxrc 5 ,
.Xr detox.tbl 5 ,
.Xr detoxrc 5 ,
.Xr ascii 7 ,
.Xr iso_8859-1 7 ,
.Xr unicode 7 ,
.Xr utf-8 7 .
.Xr utf-8 7
.Sh HISTORY
.Nm
was originally designed to clean up files that I had received from
Expand Down
Binary file modified man/detox.1.pdf
Binary file not shown.
4 changes: 2 additions & 2 deletions man/detox.tbl.5
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ same rules that apply to sscanf apply here.
Translation can be a string or a quoted string, with either single or
double quotes.
.El
.Sh EXAMPLE
.Sh EXAMPLES
The following example shows a portion of a
.Ar safe
table, with only a few character replacements specified.
Expand Down Expand Up @@ -115,7 +115,7 @@ for more details on the various filter types.
.Xr ascii 7 ,
.Xr iso_8859-1 7 ,
.Xr unicode 7 ,
.Xr utf-8 7 .
.Xr utf-8 7
.Sh AUTHORS
detox was written by
.An "Doug Harple" .
Binary file modified man/detox.tbl.5.pdf
Binary file not shown.
9 changes: 2 additions & 7 deletions man/detoxrc.5
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ on ASCII characters.
.It Cm # comments
Any thing after a # on any line is ignored.
.El
.Sh EXAMPLE
.Sh EXAMPLES
.Bd -literal
sequence default {
uncgi;
Expand Down Expand Up @@ -186,20 +186,17 @@ or creating a copy of
and updating your
.Pa detoxrc
file.
.Pp
.Ss Rules that apply anywhere in the filename:
.Bl -column -offset indent ".Sy Removed" ".Sy Original"
.It Sy Safe Ta Sy Original
.It _and_ Ta &
.It _ Ta \fIspace\fR ` \&! @ $ * \e | \&: \&; \&" ' < > \&? /
.It - Ta \&( \&) \&[ \&] { }
.El
.Pp
.Sh WIPEUP
The following characters are translated by the
.Ar wipeup
filter.
.Pp
.Ss Rules that apply anywhere in the filename:
.Bl -column -offset indent ".Sy Wipeup" ".Sy Original"
.It Sy Wipeup Ta Sy Original
Expand All @@ -208,7 +205,6 @@ filter.
.It - Ta --
.It _ Ta __
.El
.Pp
.Ss Rules that apply only at the beginning of a filename:
Any leading dashes are stripped to prevent programs from interpreting
these files as command line options.
Expand All @@ -224,7 +220,6 @@ these files as command line options.
.It . Ta ._
.It . Ta _.
.El
.Pp
.Sh SEE ALSO
.Xr detox 1 ,
.Xr inline-detox 1 ,
Expand All @@ -233,7 +228,7 @@ these files as command line options.
.Xr cp1252 7 ,
.Xr iso_8859-1 7 ,
.Xr unicode 7 ,
.Xr utf-8 7 .
.Xr utf-8 7
.Sh AUTHORS
detox was written by
.An "Doug Harple" .
Binary file modified man/detoxrc.5.pdf
Binary file not shown.
4 changes: 2 additions & 2 deletions man/inline-detox.1
Original file line number Diff line number Diff line change
Expand Up @@ -117,12 +117,12 @@ listing any changes and returning the result to the output stream.
.El
.Sh SEE ALSO
.Xr detox 1 ,
.Xr detoxrc 5 ,
.Xr detox.tbl 5 ,
.Xr detoxrc 5 ,
.Xr ascii 7 ,
.Xr iso_8859-1 7 ,
.Xr unicode 7 ,
.Xr utf-8 7 .
.Xr utf-8 7
.Sh HISTORY
.Nm
was originally designed to clean up files that I had received from
Expand Down
Binary file modified man/inline-detox.1.pdf
Binary file not shown.

0 comments on commit c596970

Please sign in to comment.