xref: /freebsd/share/examples/mdoc/example.1 (revision 83ac79599f6b94c57321ce3738fc28d1fa6a6c60)
1.\"
2.\" Copyright (c) [year] [your name]
3.\"
4.\" SPDX-License-Identifier: BSD-2-Clause
5.\"
6.\" Note: The date here should be updated whenever a non-trivial
7.\" change is made to the manual page.
8.Dd December 8, 1999
9.Dt EXAMPLE 1
10.Os
11.Sh NAME
12.Nm example
13.Nd "example command manual page"
14.Sh SYNOPSIS
15.Nm
16.Op Fl abc
17.Op Fl d Ar argument
18.Ar file
19.Sh DESCRIPTION
20This is an example manual page for the
21.Nm
22command.
23It is intended that this example can be used as a template
24when writing a new manual page.
25.Pp
26The options are as follows:
27.Bl -tag -width "-d argument"
28.It Fl a
29Example optional
30.Fl a
31option.
32.It Fl b
33Example optional
34.Fl b
35option.
36.It Fl c
37Example optional
38.Fl c
39option.
40.It Fl d Ar argument
41Example optional
42.Fl d
43option with required argument
44.Ar argument .
45.It Ar file
46Required argument
47.Ar file .
48.El
49.Sh ENVIRONMENT
50The
51.Nm
52command ignores the
53.Ev EXAMPLE
54environment variable.
55.Sh FILES
56.Bl -tag -width "/dev/null" -compact
57.It Pa /dev/null
58Example of a file in the
59.Sx FILES
60section.
61.El
62.Sh EXIT STATUS
63.Ex -std
64.Sh EXAMPLES
65The following is an example of a typical usage
66of the
67.Nm
68command:
69.Pp
70.Dl "example -abc -d xyzzy /dev/null"
71.Sh DIAGNOSTICS
72The command may fail for one of the following reasons:
73.Bl -diag
74.It "example error message"
75An example of an error message.
76.It "another example error message."
77Self explanatory.
78.El
79.Sh COMPATIBILITY
80The
81.Nm
82command has no known compatibility issues.
83.Sh SEE ALSO
84.Xr example 3 ,
85.Xr example 4 ,
86.Xr mdoc 7 ,
87.Xr example 9
88.Rs
89.%A "A. B. Author"
90.%T "Example RFC Title"
91.%O RFC0000
92.Re
93.Rs
94.%A "A. B. Author"
95.%B "Example Book Title"
96.%O ISBN-0-000-00000-0
97.Re
98.Rs
99.%A "A. B. Author"
100.%D "January 1997"
101.%J "Example Journal Name"
102.%T "Example Article Title"
103.Re
104.Sh STANDARDS
105If the command conforms to some standard, such as
106.St -p1003.2
107or
108.St -isoC ,
109it should be noted here.
110.Sh HISTORY
111The
112.Nm
113manual page example first appeared in
114.Fx 2.2 .
115.Pp
116Some other common
117.Sx HISTORY
118section examples are:
119.Pp
120The
121.Nm
122manual page example first appeared in
123.Bx 4.4 .
124.Pp
125The
126.Nm
127manual page example first appeared in
128.At v6 .
129.Sh AUTHORS
130This
131manual page was written by
132.An Mike Pritchard Aq Mt mpp@FreeBSD.org .
133.Sh BUGS
134The actual code for this command is vaporware.
135