updated ali-flist, with batch edit of others
[mmh] / man / dp.man
1 .\"
2 .\" %nmhwarning%
3 .\" $Id$
4 .\"
5 .TH DP %manext8% "%nmhdate%" MH.6.8 [%nmhversion%]
6 .SH NAME
7 dp \- parse dates 822-style
8 .SH SYNOPSIS
9 .HP 5
10 .B %libdir%/dp
11 .RB [ \-form
12 .IR formatfile ]
13 .RB [ \-format
14 .IR string ]
15 .RB [ \-width
16 .IR columns ]
17 .RB [ \-version ]
18 .RB [ \-help ] 
19 .I dates
20 \&...
21 .SH DESCRIPTION
22 .B Dp
23 is a program that parses dates according to the ARPA Internet standard.
24 It also understands many non\-standard formats,
25 such as those produced by TOPS\-20 sites and some UNIX sites using
26 .BR ctime (3).
27 It is useful for seeing how
28 .B nmh
29 will interpret a date.
30 .PP
31 The
32 .B dp
33 program treats each argument as a single date,
34 and prints the date out in the official 822\-format.
35 Hence, it is usually best to enclose each argument in double\-quotes for the
36 shell.
37 .PP
38 To override the output format used by
39 .BR dp ,
40 the
41 .B \-format
42 .I string
43 or
44 .B \-format
45 .I file
46 switches are used.
47 This permits individual fields of the address to be extracted with ease.
48 The string is simply a format string and the file is simply a format file.
49 See
50 .BR mh\-format (5)
51 for the details.
52 .PP
53 Here is the default format string used by
54 .BR dp :
55 .PP
56 .RS 5
57 .nf
58 %<(nodate{text})error: %{text}%|%(putstr(pretty{text}))%>
59 .fi
60 .RE
61 .PP
62 which says that if an error was detected, print the error, a `:',
63 and the date in error.
64 Otherwise, output the 822\-proper format of the date.
65
66 .SH FILES
67 .fc ^ ~
68 .nf
69 .ta \w'/usr/local/nmh/etc/ExtraBigFileName  'u
70 ^$HOME/\&.mh\(ruprofile~^The user profile
71
72 .SH "PROFILE COMPONENTS"
73 None
74
75 .SH "SEE ALSO"
76 ap(8),
77 .I "Standard for the Format of ARPA Internet Text Messages"
78 (RFC\-822)
79
80 .SH "DEFAULTS"
81 .nf
82 .RB ` \-format "' default as described above"
83 .RB ` \-width "' default to the width of the terminal"
84
85 .SH CONTEXT
86 None
87
88 .SH BUGS
89 The argument to the
90 .B \-format
91 switch must be interpreted as a single token by the shell that invokes
92 .BR dp .
93 Therefore, one must usually place the argument to this switch inside double\-quotes.