[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.18

1.18    ! mickey      1: .\"    $OpenBSD: calendar.1,v 1.17 2001/10/11 20:10:30 mickey 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.
1.16      mickey     97: .Pp
                     98: To enforce special date calculation mode for Cyrillic calendars
                     99: you should specify
                    100: .Dq LANG=<local_name>
                    101: and
1.17      mickey    102: .Dq BODUN=<bodun_prefix>
                    103: where <local_name> can be ru_RU.KOI8-R, uk_UA.KOI8-U or by_BY.KOI8-B.
1.3       millert   104: .Pp
                    105: Other lines should begin with a month and day.
1.1       deraadt   106: They may be entered in almost any format, either numeric or as character
                    107: strings.
1.3       millert   108: If proper locale is set, national months and weekdays
                    109: names can be used.
1.5       aaron     110: A single asterisk (`*') matches every month.
1.1       deraadt   111: A day without a month matches that day of every week.
                    112: A month without a day matches the first of that month.
                    113: Two numbers default to the month followed by the day.
                    114: Lines with leading tabs default to the last entered date, allowing
                    115: multiple line specifications for a single date.
1.9       pjanzen   116: .Dq Easter
                    117: (may be followed by a positive or negative integer) is Easter for this year.
                    118: .Dq Paskha
                    119: (may be followed by a positive or negative integer) is
1.3       millert   120: Orthodox Easter for this year.
1.9       pjanzen   121: Weekdays may be followed by
                    122: .Dq -4
                    123: .Li ...
                    124: .Dq +5
                    125: (aliases last, first, second, third, fourth) for moving events like
                    126: .Dq the last Monday in April .
1.3       millert   127: .Pp
1.5       aaron     128: By convention, dates followed by an asterisk
                    129: .Pq Sq *
                    130: are not fixed, i.e., change
1.1       deraadt   131: from year to year.
                    132: .Pp
1.5       aaron     133: Day descriptions start after the first <tab> character in the line;
                    134: if the line does not contain a <tab> character, it isn't printed out.
                    135: If the first character in the line is a <tab> character, it is treated as
1.8       pjanzen   136: the continuation of the previous description.
1.3       millert   137: .Pp
1.9       pjanzen   138: The calendar file is preprocessed by
1.1       deraadt   139: .Xr cpp 1 ,
                    140: allowing the inclusion of shared files such as company holidays or
                    141: meetings.
                    142: If the shared file is not referenced by a full pathname,
                    143: .Xr cpp 1
                    144: searches in the current (or home) directory first, and then in the
                    145: directory
                    146: .Pa /usr/share/calendar .
                    147: Empty lines and lines protected by the C commenting syntax
                    148: .Pq Li /* ... */
                    149: are ignored.
                    150: .Pp
1.5       aaron     151: Some possible calendar entries (<tab> characters are highlighted by a
                    152: \fB\et\fR sequence):
1.1       deraadt   153: .Bd -unfilled -offset indent
1.3       millert   154: LANG=C
                    155: Easter=Ostern
                    156:
                    157: #include <calendar.usholiday>
                    158: #include <calendar.birthday>
                    159:
                    160: 6/15\fB\et\fRJune 15 (if ambiguous, will default to month/day).
                    161: Jun. 15\fB\et\fRJune 15.
                    162: 15 June\fB\et\fRJune 15.
                    163: Thursday\fB\et\fREvery Thursday.
                    164: June\fB\et\fREvery June        1st.
                    165: 15 *\fB\et\fR15th of every month.
1.1       deraadt   166:
1.3       millert   167: May Sun+2\fB\et\fRsecond Sunday        in May (Muttertag)
                    168: 04/SunLast\fB\et\fRlast        Sunday in April,
                    169: \fB\et\fRsummer        time in Europe
                    170: Easter\fB\et\fREaster
                    171: Ostern-2\fB\et\fRGood Friday (2        days before Easter)
                    172: Paskha\fB\et\fROrthodox        Easter
1.1       deraadt   173: .Ed
                    174: .Sh FILES
1.5       aaron     175: .Bl -tag -width ~/.calendar/calendar -compact
1.3       millert   176: .It Pa calendar
                    177: file in current directory
                    178: .It Pa ~/.calendar
1.5       aaron     179: file in home directory (which
1.9       pjanzen   180: .Nm
1.5       aaron     181: .Xr chdir 1 's
                    182: into if it exists)
1.3       millert   183: .It Pa ~/.calendar/calendar
1.5       aaron     184: file to use if no calendar file exists in the current directory
1.3       millert   185: .It Pa ~/.calendar/nomail
1.9       pjanzen   186: .Nm
1.5       aaron     187: will not send mail if this file exists
1.1       deraadt   188: .It Pa calendar.birthday
1.5       aaron     189: births and deaths of famous (and not-so-famous) people
1.1       deraadt   190: .It Pa calendar.christian
1.8       pjanzen   191: Christian holidays (should be updated yearly by the local system administrator
1.5       aaron     192: so that roving holidays are set correctly for the current year)
1.1       deraadt   193: .It Pa calendar.computer
1.5       aaron     194: days of special significance to computer people
1.18    ! mickey    195: .It Pa calendar.fictional
        !           196: Fantasy and Fiction dates (mostly LOTR)
1.1       deraadt   197: .It Pa calendar.history
1.5       aaron     198: everything else, mostly U.S. historical events
1.1       deraadt   199: .It Pa calendar.holiday
1.5       aaron     200: other holidays (including the not-well-known, obscure, and
1.1       deraadt   201: .Em really
1.5       aaron     202: obscure)
1.1       deraadt   203: .It Pa calendar.judaic
1.5       aaron     204: Jewish holidays (should be updated yearly by the local system administrator
                    205: so that roving holidays are set correctly for the current year)
1.1       deraadt   206: .It Pa calendar.music
1.5       aaron     207: musical events, births, and deaths (strongly oriented toward rock n' roll)
1.18    ! mickey    208: .It Pa calendar.pagan
        !           209: Pagan holidays, celebrations and festivals
1.1       deraadt   210: .It Pa calendar.usholiday
1.9       pjanzen   211: U.S. holidays
1.18    ! mickey    212: .It Pa calendar.world
        !           213: World wide calendar
        !           214: .It Pa calendar.croatian
        !           215: Croatian calendar
1.3       millert   216: .It Pa calendar.german
1.5       aaron     217: German calendar
1.3       millert   218: .It Pa calendar.russian
1.5       aaron     219: Russian calendar
1.1       deraadt   220: .El
                    221: .Sh SEE ALSO
                    222: .Xr at 1 ,
1.12      aaron     223: .Xr cal 1 ,
1.1       deraadt   224: .Xr cpp 1 ,
1.5       aaron     225: .Xr mail 1 ,
                    226: .Xr cron 8
1.1       deraadt   227: .Sh COMPATIBILITY
                    228: The
1.11      aaron     229: .Nm
1.1       deraadt   230: program previously selected lines which had the correct date anywhere
                    231: in the line.
1.12      aaron     232: This is no longer true: the date is only recognized when it occurs
1.3       millert   233: at the beginning of a line.
1.1       deraadt   234: .Sh HISTORY
                    235: A
                    236: .Nm
1.3       millert   237: command appeared in
1.1       deraadt   238: .At v7 .
                    239: .Sh BUGS
1.9       pjanzen   240: .Nm
1.5       aaron     241: doesn't handle Jewish holidays or moon phases.