FactorPad
Faster Learning Tutorials

Linux calendar command summary with examples

calendar allows you to display reminders and calendar updates.
  1. Purpose - Learn what calendar is for and how to find help.
  2. Options - Review a few common options and arguments.
  3. Examples - Walk through code examples with calendar.
  4. A tip - Finish off with one more insight.
Paul Alan Davis, CFA, October 22, 2016
Updated: August 1, 2018
In this tutorial, 41 of 100, below find a 3-4 minute introductory video, a text-based tutorial and all of the code examples from the video.

Outline Back Next

~/ home  / tech  / linux essentials  / calendar command


The Linux calendar command

Beginner

Learn to manage a team calendar at the Linux command line.

Video Tutorial

Linux calendar command summary with examples (3:31)

Videos can also be accessed from the YouTube Playlist.

Video Script

The Command and Why You Need It

Our forty-first word, or command to memorize is calendar from our category System.

calendar allows you to display reminders and calendar updates.

Recall that we just finished a set of 10 video (tutorials) on text processing, ending with full-blown programming-like commands like grep and sed, so you deserve a break with an easy topic like calendar.

Before we start, it helps to think of commands as mini programs and most follow this structure: command -option(s) argument(s).

The calendar command has 8 options, and no arguments.

Unlike most commands, help isn't available with double-dash --help, so I suggest using the man calendar command for documentation. The default is today and tomorrow with weekends lumped together. With -A you can change this default to a different number of days, and -B allows you to look back in time.

A system administrator can use the -a option to send calendar items to all users via email.

So why is calendar an important command? Well, it is important for everyone to be kept on the same page, of the calendar that is. And now you know how to do that.

Demonstration

Okay, the best way to embed this in your memory is by typing in your own terminal window.

Find this on your Mac using a program called Terminal. On Linux use Terminal or Konsole, and currently Microsoft is adding this functionality to Windows.

Here we go. Let's do a calendar optionless.

$ calendar Oct 22 Franz Liszt born, 1811 Oct 22 Pablo Casals dies in Puerto Rico, 1973 Oct 22 Jean-Sebastien Pedron <dumbbell@FreeBSD.org> born in Redon, Ille-et-Vilaine, France, 1980 Oct 22 N'oubliez pas les Élodie ! Oct 22 Bonne fête aux Nunillon ! Oct 22 Aujourd'hui, c'est la St(e) Salomé. Oct 22 Franz Liszt in Raiding (Ungarn) geboren, 1811 Oct 22 Elõd Oct 23 Battle of Leyte Gulf begins, 1944 Oct 23 Day of the 1956 revolution in Hungary Oct 23 Earth created at 6:30 AM, 4004BC. Oct 23 Swallows leave Capistrano Oct 23 Chulalongkron's Day in Thailand Oct 23 UEO signed in Paris (military cooperation), 1954 Oct 23 José de San Martín declara la libertad de imprenta en el Perú, 1821 Oct 23 Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> born in Brasilia, Distrito Federal, Brazil, 1976 Oct 23 N'oubliez pas les Jean ! Oct 23 Gelée d'octobre Rend le vigneron sobre. Oct 23 Volksabstimmung im Saargebiet, 1955 Oct 23 1956-os forradalom ünnepe Oct 23 Gyöngyi $ clear

And it reports historical events today and one day forward by default.

Next, let's do an ls directory listing in /usr/share/calendar to see the different calendars available.

$ ls /usr/share/calendar calendar.all calendar.eu calendar.judaic.2017 calendar.ukrainian calendar.argentina calendar.freebsd calendar.judaic.2018 calendar.unitedkingdom calendar.australia calendar.french calendar.kazakhstan calendar.usholiday calendar.belgium calendar.german calendar.lotr calendar.world calendar.birthday calendar.history calendar.music de_AT calendar.christian calendar.holiday calendar.newzealand de-DE calendar.computer calendar.hungarian calendar.pagan fr_FR calendar.coratian calendar.judaic calendar.russian hr_HR calendar.debian calendar.judaic.2014 calendar.southafrican hu_HU calendar.discordian calendar.judaic.2015 calendar.thai ru_RU calendar.dutch calendar.judaic.2016 calendar.ubuntu uk_UA

And if you're particularly nationalistic or religious you do have a few choices here.

And last, let's throw in a -B option and look back one day too.

$ calendar -B 1 Oct 24 Salamon Oct 24 MeждyнapoднЫй дeнЬ ООH Oct 25 Pablo Picasso born in Malaga, Spain, 1881 Oct 25 DEC announces VAX-11/780 Oct 25 The UN removes Taiwan and admits the People's Republic of China, 1971 Oct 25 End of War of the Ring Oct 25 Taiwan Restoration Day in Taiwan Oct 25 St. Crispin's day, patron saint of shoemakers Oct 25* Parshat Noach Oct 25 Georges Bizet is born in Paris, France, 1838 Oct 25 Jon Anderson (Yes) is born in Lancashire, England, 1944 Oct 25 The Rolling Stones appear on The Ed Sullivan Show, 1964 Oct 25 Creation of the PESC (military and security policy), 1998 Oct 25 Eric Melville <eric@FreeBSD.org> born in Los Gatos, California, United States, 1980 Oct 25 Aujourd'hui, c'est la St(e) Crépin. Oct 25 N'oubliez pas les Crépinien ! Oct 25 Bonne fête aux Chrysanthe ! Oct 25 Aujourd'hui, c'est la St(e) Darie. Oct 25 N'oubliez pas les Enguerran ! Oct 25 Pour saint Crépin, mort aux mouches. Oct 25 Schwarzer Freitag in New York, Beginn der Weltwirtschaftskrise, 1929 Oct 25 Deutsch-italienischer Vertrag, Achse Berlin-Rom, 1936 Oct 25 Georges Bizet in Paris geboren, 1838 Oct 25 Blanka, Bianka Oct 25 Anniversary Day (Hawke's Bay) Oct 25 Дeнь тaможeнникa

A Final Tip

Okay now you know how to use calendar. And you know the syntax for commands, options and arguments.

One last tip about the calendar command. So yes, some organizations do create and distribute custom calendars; however, most I know do try to keep it light-hearted and fun.

Okay, thanks for visiting today. I hope this was a helpful introduction to the calendar command.


Learn More About The Series

For an overview of the 100 videos, the 8 quizzes, a cheat sheet, the categories and a Q&A section, visit:


What's Next?

YouTube is just one social venue where we can connect with you. Subscribe here and check out other links in the footer.

  • For the Outline to all 100 tutorials, click Outline.
  • To go back to the sed command, hit Back.
  • To tackle the related command cal, click Next.

Outline Back Next

~/ home  / tech  / linux essentials  / calendar command



 
 
Keywords:
Linux calendar command
calendar linux
unix calendar
linux calendar updates
team calendar
display reminders in linux
historical events calendar
linux calendar updates
calendar options
organization history calendar
calendar history
calandar command tutorial
create a calendar
team calendar
linux calendar app
calendar man page