1CAL(1)                           User Commands                          CAL(1)
2
3
4

NAME

6       cal - display a calendar
7

SYNOPSIS

9       cal [options] [[[day] month] year]
10       cal [options] [timestamp|monthname]
11

DESCRIPTION

13       cal  displays  a  simple  calendar.  If no arguments are specified, the
14       current month is displayed.
15
16       The month may be specified as a number (1-12), as a month name or as an
17       abbreviated month name according to the current locales.
18
19       Two  different  calendar systems are used, Gregorian and Julian.  These
20       are nearly identical systems with Gregorian making a  small  adjustment
21       to  the frequency of leap years; this facilitates improved synchroniza‐
22       tion with solar events like  the  equinoxes.   The  Gregorian  calendar
23       reform  was  introduced in 1582, but its adoption continued up to 1923.
24       By default cal uses the adoption date of 3 Sept 1752.  From  that  date
25       forward  the  Gregorian  calendar  is displayed; previous dates use the
26       Julian calendar system.  11 days were removed at the time  of  adoption
27       to  bring  the  calendar in sync with solar events.  So Sept 1752 has a
28       mix of Julian and Gregorian dates by which the 2nd is followed  by  the
29       14th (the 3rd through the 13th are absent).
30
31       Optionally,  either the proleptic Gregorian calendar or the Julian cal‐
32       endar may be used exclusively.  See --reform below.
33

OPTIONS

35       -1, --one
36              Display single month output.  (This is the default.)
37
38       -3, --three
39              Display three months spanning the date.
40
41       -n , --months number
42              Display number of months, starting from the month containing the
43              date.
44
45       -S, --span
46              Display months spanning the date.
47
48       -s, --sunday
49              Display Sunday as the first day of the week.
50
51       -m, --monday
52              Display Monday as the first day of the week.
53
54       -v, --vertical
55              Display using a vertical layout (aka ncal mode).
56
57       --iso  Display  the  proleptic  Gregorian  calendar  exclusively.  This
58              option does not affect week numbers and the  first  day  of  the
59              week.  See --reform below.
60
61       -j, --julian
62              Use  day-of-year  numbering  for  all calendars.  These are also
63              called ordinal days.  Ordinal days range from 1  to  366.   This
64              option does not switch from the Gregorian to the Julian calendar
65              system, that is controlled by the --reform option.
66
67              Sometimes Gregorian calendars using ordinal dates  are  referred
68              to  as  Julian calendars.  This can be confusing due to the many
69              date related conventions that use Julian in their  name:  (ordi‐
70              nal)  julian date, julian (calendar) date, (astronomical) julian
71              date, (modified) julian date, and more.  This  option  is  named
72              julian,  because  ordinal  days  are identified as julian by the
73              POSIX standard.  However, be aware that cal also uses the Julian
74              calendar system.  See DESCRIPTION above.
75
76       --reform val
77              This  option  sets  the  adoption date of the Gregorian calendar
78              reform.  Calendar dates previous to reform use the Julian calen‐
79              dar  system.  Calendar dates after reform use the Gregorian cal‐
80              endar system.  The argument val can be:
81
82              · 1752 - sets 3 September 1752 as  the  reform  date  (default).
83                This  is when the Gregorian calendar reform was adopted by the
84                British Empire.
85
86              · gregorian - display  Gregorian  calendars  exclusively.   This
87                special  placeholder  sets  the reform date below the smallest
88                year that cal can use; meaning all calendar  output  uses  the
89                Gregorian  calendar system.  This is called the proleptic Gre‐
90                gorian calendar, because dates prior to the calendar  system's
91                creation use extrapolated values.
92
93              · iso  - alias of gregorian.  The ISO 8601 standard for the rep‐
94                resentation of dates  and  times  in  information  interchange
95                requires using the proleptic Gregorian calendar.
96
97              · julian  -  display Julian calendars exclusively.  This special
98                placeholder sets the reform date above the largest  year  that
99                cal  can use; meaning all calendar output uses the Julian cal‐
100                endar system.
101
102              See DESCRIPTION above.
103
104       -y, --year
105              Display a calendar for the whole year.
106
107       -Y, --twelve
108              Display a calendar for the next twelve months.
109
110       -w, --week[=number]
111              Display week numbers in the  calendar  (US  or  ISO-8601).   See
112              NOTES section for more details.
113
114       --color[=when]
115              Colorize  the  output.   The optional argument when can be auto,
116              never or always.  If the when argument is omitted,  it  defaults
117              to  auto.   The colors can be disabled; for the current built-in
118              default see the --help output.  See also the COLORS section.
119
120       -V, --version
121              Display version information and exit.
122
123       -h, --help
124              Display help text and exit.
125

PARAMETERS

127       Single digits-only parameter (e.g., 'cal 2020')
128              Specifies the year to be displayed; note the year must be  fully
129              specified: cal 89 will not display a calendar for 1989.
130
131       Single string parameter (e.g., 'cal tomorrow' or 'cal August')
132              Specifies  timestamp  or  a  month  name  (or  abbreviated name)
133              according to the current locales.
134
135              The special placeholders are accepted  when  parsing  timestamp,
136              "now"  may  be used to refer to the current time, "today", "yes‐
137              terday", "tomorrow" refer to of the current day, the day  before
138              or the next day, respectively.
139
140              The relative date specifications are also accepted, in this case
141              "+" is evaluated to the current time  plus  the  specified  time
142              span.  Correspondingly, a time span that is prefixed with "-" is
143              evaluated to the current time minus the specified time span, for
144              example '+2days'. Instead of prefixing the time span with "+" or
145              "-", it may also be suffixed with a space and the word "left" or
146              "ago" (for example '1 week ago').
147
148       Two parameters (e.g., 'cal 11 2020')
149              Denote the month (1 - 12) and year.
150
151       Three parameters (e.g., 'cal 25 11 2020')
152              Denote the day (1-31), month and year, and the day will be high‐
153              lighted if the calendar is  displayed  on  a  terminal.   If  no
154              parameters  are  specified, the current month's calendar is dis‐
155              played.
156

NOTES

158       A year starts on January 1.  The first day of the week is determined by
159       the locale or the --sunday and --monday options.
160
161       The  week numbering depends on the choice of the first day of the week.
162       If it is Sunday then the customary North American  numbering  is  used,
163       where 1 January is in week number 1.  If it is Monday (-m) then the ISO
164       8601 standard week numbering is used, where the first  Thursday  is  in
165       week number 1.
166

COLORS

168       Implicit coloring can be disabled as follows:
169
170              touch /etc/terminal-colors.d/cal.disable
171
172       See terminal-colors.d(5) for more details about colorization configura‐
173       tion.
174

HISTORY

176       A cal command appeared in Version 6 AT&T UNIX.
177

BUGS

179       The default cal output uses 3 September 1752 as the Gregorian  calendar
180       reform  date.   The  historical  reform   dates  for the other locales,
181       including its introduction in October 1582, are not implemented.
182
183       Alternative calendars, such as the Umm al-Qura, the  Solar  Hijri,  the
184       Ge'ez, or the lunisolar Hindu, are not supported.
185

AVAILABILITY

187       The cal command is part of the util-linux package and is available from
188       https://www.kernel.org/pub/linux/utils/util-linux/.
189
190
191
192util-linux                       January 2018                           CAL(1)
Impressum