[BACK]Return to calendar.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / calendar

Annotation of src/usr.bin/calendar/calendar.1, Revision 1.15

1.15    ! mickey      1: .\"    $OpenBSD: calendar.1,v 1.14 2000/04/15 11:45:54 aaron Exp $
1.1       deraadt     2: .\"
                      3: .\" Copyright (c) 1989, 1990, 1993
1.3       millert     4: .\"     The Regents of the University of California.  All rights reserved.
1.1       deraadt     5: .\"
                      6: .\" Redistribution and use in source and binary forms, with or without
                      7: .\" modification, are permitted provided that the following conditions
                      8: .\" are met:
                      9: .\" 1. Redistributions of source code must retain the above copyright
                     10: .\"    notice, this list of conditions and the following disclaimer.
                     11: .\" 2. Redistributions in binary form must reproduce the above copyright
                     12: .\"    notice, this list of conditions and the following disclaimer in the
                     13: .\"    documentation and/or other materials provided with the distribution.
                     14: .\" 3. All advertising materials mentioning features or use of this software
                     15: .\"    must display the following acknowledgement:
1.3       millert    16: .\"     This product includes software developed by the University of
                     17: .\"     California, Berkeley and its contributors.
1.1       deraadt    18: .\" 4. Neither the name of the University nor the names of its contributors
                     19: .\"    may be used to endorse or promote products derived from this software
                     20: .\"    without specific prior written permission.
                     21: .\"
                     22: .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
                     23: .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
                     24: .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
                     25: .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
                     26: .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
                     27: .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
                     28: .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
                     29: .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
                     30: .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
                     31: .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
                     32: .\" SUCH DAMAGE.
                     33: .\"
1.3       millert    34: .\"     @(#)calendar.1  8.1 (Berkeley) 6/29/93
1.1       deraadt    35: .\"
                     36: .Dd June 29, 1993
                     37: .Dt CALENDAR 1
                     38: .Os
                     39: .Sh NAME
                     40: .Nm calendar
                     41: .Nd reminder service
                     42: .Sh SYNOPSIS
1.10      aaron      43: .Nm calendar
1.1       deraadt    44: .Op Fl a
1.3       millert    45: .Op Fl A Ar num
1.15    ! mickey     46: .Op Fl b
1.3       millert    47: .Op Fl B Ar num
1.15    ! mickey     48: .Op Fl f Ar calendarfile
1.7       millert    49: .Op Fl t Ar [[[cc]yy][mm]]dd
1.1       deraadt    50: .Sh DESCRIPTION
1.3       millert    51: The
1.9       pjanzen    52: .Nm
1.1       deraadt    53: utility checks the current directory or the directory specified by the
1.5       aaron      54: .Ev CALENDAR_DIR
1.1       deraadt    55: environment variable for a file named
                     56: .Pa calendar
                     57: and displays lines that begin with either today's date
                     58: or tomorrow's.
                     59: On Fridays, events on Friday through Monday are displayed.
                     60: .Pp
1.12      aaron      61: The options are as follows:
1.1       deraadt    62: .Bl -tag -width Ds
                     63: .It Fl a
1.9       pjanzen    64: Process the
                     65: .Dq calendar
                     66: files of all users and mail the results
1.1       deraadt    67: to them.
1.14      aaron      68: This requires superuser privileges.
1.3       millert    69: .It Fl A Ar num
1.5       aaron      70: Print lines from today and next
1.3       millert    71: .Ar num
1.5       aaron      72: days (forward, future).
1.15    ! mickey     73: .It Fl b
        !            74: Enforce special date calculation mode for KOI8 calendars.
1.3       millert    75: .It Fl B Ar num
1.5       aaron      76: Print lines from today and previous
1.3       millert    77: .Ar num
1.5       aaron      78: days (backward, past).
1.3       millert    79: .It Fl f Pa calendarfile
1.5       aaron      80: Use
1.3       millert    81: .Pa calendarfile
1.5       aaron      82: as the default calendar file.
1.7       millert    83: .It Fl t Ar [[[cc]yy][mm]]dd
1.9       pjanzen    84: Act like the specified value is
                     85: .Dq today
                     86: instead of using the current date.
1.1       deraadt    87: .El
                     88: .Pp
1.3       millert    89: To handle calendars in your national code table you can specify
                     90: .Dq LANG=<locale_name>
1.13      aaron      91: in the calendar file as early as possible.
                     92: To handle national Easter names in the calendars,
1.3       millert    93: .Dq Easter=<national_name>
                     94: (for Catholic Easter) or
                     95: .Dq Paskha=<national_name>
                     96: (for Orthodox Easter) can be used.
                     97: .Pp
                     98: Other lines should begin with a month and day.
1.1       deraadt    99: They may be entered in almost any format, either numeric or as character
                    100: strings.
1.3       millert   101: If proper locale is set, national months and weekdays
                    102: names can be used.
1.5       aaron     103: A single asterisk (`*') matches every month.
1.1       deraadt   104: A day without a month matches that day of every week.
                    105: A month without a day matches the first of that month.
                    106: Two numbers default to the month followed by the day.
                    107: Lines with leading tabs default to the last entered date, allowing
                    108: multiple line specifications for a single date.
1.9       pjanzen   109: .Dq Easter
                    110: (may be followed by a positive or negative integer) is Easter for this year.
                    111: .Dq Paskha
                    112: (may be followed by a positive or negative integer) is
1.3       millert   113: Orthodox Easter for this year.
1.9       pjanzen   114: Weekdays may be followed by
                    115: .Dq -4
                    116: .Li ...
                    117: .Dq +5
                    118: (aliases last, first, second, third, fourth) for moving events like
                    119: .Dq the last Monday in April .
1.3       millert   120: .Pp
1.5       aaron     121: By convention, dates followed by an asterisk
                    122: .Pq Sq *
                    123: are not fixed, i.e., change
1.1       deraadt   124: from year to year.
                    125: .Pp
1.5       aaron     126: Day descriptions start after the first <tab> character in the line;
                    127: if the line does not contain a <tab> character, it isn't printed out.
                    128: If the first character in the line is a <tab> character, it is treated as
1.8       pjanzen   129: the continuation of the previous description.
1.3       millert   130: .Pp
1.9       pjanzen   131: The calendar file is preprocessed by
1.1       deraadt   132: .Xr cpp 1 ,
                    133: allowing the inclusion of shared files such as company holidays or
                    134: meetings.
                    135: If the shared file is not referenced by a full pathname,
                    136: .Xr cpp 1
                    137: searches in the current (or home) directory first, and then in the
                    138: directory
                    139: .Pa /usr/share/calendar .
                    140: Empty lines and lines protected by the C commenting syntax
                    141: .Pq Li /* ... */
                    142: are ignored.
                    143: .Pp
1.5       aaron     144: Some possible calendar entries (<tab> characters are highlighted by a
                    145: \fB\et\fR sequence):
1.1       deraadt   146: .Bd -unfilled -offset indent
1.3       millert   147: LANG=C
                    148: Easter=Ostern
                    149:
                    150: #include <calendar.usholiday>
                    151: #include <calendar.birthday>
                    152:
                    153: 6/15\fB\et\fRJune 15 (if ambiguous, will default to month/day).
                    154: Jun. 15\fB\et\fRJune 15.
                    155: 15 June\fB\et\fRJune 15.
                    156: Thursday\fB\et\fREvery Thursday.
                    157: June\fB\et\fREvery June        1st.
                    158: 15 *\fB\et\fR15th of every month.
1.1       deraadt   159:
1.3       millert   160: May Sun+2\fB\et\fRsecond Sunday        in May (Muttertag)
                    161: 04/SunLast\fB\et\fRlast        Sunday in April,
                    162: \fB\et\fRsummer        time in Europe
                    163: Easter\fB\et\fREaster
                    164: Ostern-2\fB\et\fRGood Friday (2        days before Easter)
                    165: Paskha\fB\et\fROrthodox        Easter
1.1       deraadt   166: .Ed
                    167: .Sh FILES
1.5       aaron     168: .Bl -tag -width ~/.calendar/calendar -compact
1.3       millert   169: .It Pa calendar
                    170: file in current directory
                    171: .It Pa ~/.calendar
1.5       aaron     172: file in home directory (which
1.9       pjanzen   173: .Nm
1.5       aaron     174: .Xr chdir 1 's
                    175: into if it exists)
1.3       millert   176: .It Pa ~/.calendar/calendar
1.5       aaron     177: file to use if no calendar file exists in the current directory
1.3       millert   178: .It Pa ~/.calendar/nomail
1.9       pjanzen   179: .Nm
1.5       aaron     180: will not send mail if this file exists
1.1       deraadt   181: .It Pa calendar.birthday
1.5       aaron     182: births and deaths of famous (and not-so-famous) people
1.1       deraadt   183: .It Pa calendar.christian
1.8       pjanzen   184: Christian holidays (should be updated yearly by the local system administrator
1.5       aaron     185: so that roving holidays are set correctly for the current year)
1.1       deraadt   186: .It Pa calendar.computer
1.5       aaron     187: days of special significance to computer people
1.1       deraadt   188: .It Pa calendar.history
1.5       aaron     189: everything else, mostly U.S. historical events
1.1       deraadt   190: .It Pa calendar.holiday
1.5       aaron     191: other holidays (including the not-well-known, obscure, and
1.1       deraadt   192: .Em really
1.5       aaron     193: obscure)
1.1       deraadt   194: .It Pa calendar.judaic
1.5       aaron     195: Jewish holidays (should be updated yearly by the local system administrator
                    196: so that roving holidays are set correctly for the current year)
1.1       deraadt   197: .It Pa calendar.music
1.5       aaron     198: musical events, births, and deaths (strongly oriented toward rock n' roll)
1.1       deraadt   199: .It Pa calendar.usholiday
1.9       pjanzen   200: U.S. holidays
1.3       millert   201: .It Pa calendar.german
1.5       aaron     202: German calendar
1.3       millert   203: .It Pa calendar.russian
1.5       aaron     204: Russian calendar
1.1       deraadt   205: .El
                    206: .Sh SEE ALSO
                    207: .Xr at 1 ,
1.12      aaron     208: .Xr cal 1 ,
1.1       deraadt   209: .Xr cpp 1 ,
1.5       aaron     210: .Xr mail 1 ,
                    211: .Xr cron 8
1.1       deraadt   212: .Sh COMPATIBILITY
                    213: The
1.11      aaron     214: .Nm
1.1       deraadt   215: program previously selected lines which had the correct date anywhere
                    216: in the line.
1.12      aaron     217: This is no longer true: the date is only recognized when it occurs
1.3       millert   218: at the beginning of a line.
1.1       deraadt   219: .Sh HISTORY
                    220: A
                    221: .Nm
1.3       millert   222: command appeared in
1.1       deraadt   223: .At v7 .
                    224: .Sh BUGS
1.9       pjanzen   225: .Nm
1.5       aaron     226: doesn't handle Jewish holidays or moon phases.