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

PARAMETERS

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

NOTES

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

COLORS

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

BUGS

173       The default cal output uses 3 September 1752 as the Gregorian  calendar
174       reform  date.   The  historical  reform   dates  for the other locales,
175       including its introduction in October 1582, are not implemented.
176
177       Alternative calendars, such as the Umm al-Qura, the  Solar  Hijri,  the
178       Ge'ez, or the lunisolar Hindu, are not supported.
179

HISTORY

181       A cal command appeared in Version 6 AT&T UNIX.
182

AVAILABILITY

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