]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.bin/ncal/ncal.1
Upgrade to OpenSSH 5.4p1.
[FreeBSD/FreeBSD.git] / usr.bin / ncal / ncal.1
1 .\" Copyright (c) 1997 Wolfgang Helbig
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\" $FreeBSD$
26 .\"
27 .Dd March 14, 2009
28 .Dt CAL 1
29 .Os
30 .Sh NAME
31 .Nm cal ,
32 .Nm ncal
33 .Nd displays a calendar and the date of Easter
34 .Sh SYNOPSIS
35 .Nm
36 .Op Fl 3hjy
37 .Op Fl A Ar number
38 .Op Fl B Ar number
39 .Oo
40 .Op Ar month
41 .Ar year
42 .Oc
43 .Nm
44 .Op Fl 3hj
45 .Op Fl A Ar number
46 .Op Fl B Ar number
47 .Fl m Ar month
48 .Op Ar year
49 .Nm ncal
50 .Op Fl 3hjJpwy
51 .Op Fl A Ar number
52 .Op Fl B Ar number
53 .Op Fl s Ar country_code
54 .Oo
55 .Op Ar month
56 .Ar year
57 .Oc
58 .Nm ncal
59 .Op Fl 3hJeo
60 .Op Fl A Ar number
61 .Op Fl B Ar number
62 .Op Ar year
63 .Sh DESCRIPTION
64 The
65 .Nm
66 utility displays a simple calendar in traditional format and
67 .Nm ncal
68 offers an alternative layout, more options and the date of Easter.
69 The new format is a little cramped but it makes a year fit
70 on a 25x80 terminal.
71 If arguments are not specified,
72 the current month is displayed.
73 .Pp
74 The options are as follows:
75 .Bl -tag -width indent
76 .It Fl h
77 Turns off highlighting of today.
78 .It Fl J
79 Display Julian Calendar, if combined with the
80 .Fl e
81 option, display date of Easter according to the Julian Calendar.
82 .It Fl e
83 Display date of Easter (for western churches).
84 .It Fl j
85 Display Julian days (days one-based, numbered from January 1).
86 .It Fl m Ar month
87 Display the specified
88 .Ar month .
89 If
90 .Ar month
91 is specified as a decimal number, it may be followed by the letter
92 .Ql f
93 or
94 .Ql p
95 to indicate the following or preceding month of that number,
96 respectively.
97 .It Fl o
98 Display date of Orthodox Easter (Greek and Russian
99 Orthodox Churches).
100 .It Fl p
101 Print the country codes and switching days from Julian to Gregorian
102 Calendar as they are assumed by
103 .Nm ncal .
104 The country code as determined from the local environment is marked
105 with an asterisk.
106 .It Fl s Ar country_code
107 Assume the switch from Julian to Gregorian Calendar at the date
108 associated with the
109 .Ar country_code .
110 If not specified,
111 .Nm ncal
112 tries to guess the switch date from the local environment or
113 falls back to September 2, 1752.
114 This was when Great
115 Britain and her colonies switched to the Gregorian Calendar.
116 .It Fl w
117 Print the number of the week below each week column.
118 .It Fl y
119 Display a calendar for the specified year.
120 .It Fl b
121 Switch to backwards compatibility mode (for debugging).
122 .It Fl d Ar yyyy-mm-dd
123 Use
124 .Ar yyyy-mm-dd
125 as the current date (for debugging of highlighting).
126 .It Fl 3
127 Display the previous, current and next month surrounding today.
128 .It Fl A Ar number
129 Display the
130 .Ar number
131 of months after the current month.
132 .It Fl B Ar number
133 Display the
134 .Ar number
135 of months before the current month.
136 .El
137 .Pp
138 A single parameter specifies the year (1\(en9999) to be displayed;
139 note the year must be fully specified:
140 .Dq Li cal 89
141 will
142 .Em not
143 display a calendar for 1989.  Two parameters denote the month and
144 year; the month is either a number between 1 and 12, or a full or
145 abbreviated name as specified by the current locale.  Month and
146 year default to those of the current system clock and time zone (so
147 .Dq Li cal -m 8
148 will display a calendar for the month of August in the current
149 year).
150 .Pp
151 A year starts on January 1.
152 .Sh SEE ALSO
153 .Xr calendar 3 ,
154 .Xr strftime 3
155 .Sh HISTORY
156 A
157 .Nm
158 command appeared in
159 .At v5 .
160 The
161 .Nm ncal
162 command appeared in
163 .Fx 2.2.6 .
164 .Sh AUTHORS
165 The
166 .Nm ncal
167 command and manual were written by
168 .An Wolfgang Helbig Aq helbig@FreeBSD.org .
169 .Sh BUGS
170 The assignment of Julian\(enGregorian switching dates to country
171 codes is historically naive for many countries.
172 .Pp
173 Not all options are compatible and using them in different orders
174 will give varying results.