[kanchilug] [Tip] Difference between "cal" and "calendar" command

  • From: "Tha.Suresh" <jemenisuresh@xxxxxxxxx>
  • To: ILUG-C <ilugc@xxxxxxxxxxxxx>, KanchiLug <kanchilug@xxxxxxxxxxxxx>, Linux Delhi <iitdlug@xxxxxxxxxxxxxxxx>, Mlug <glug-meerut@xxxxxxxxxxxxxxxx>
  • Date: Thu, 13 Jan 2011 14:33:58 +0530

Many of us know abt "cal" command. It displays the current month calendar.

But 'calendar' command displays the history of events for current day
and next day. ;)

Ex for "cal" :

student@student-cygnus ~ $ cal
January 2011
Su Mo Tu We Th Fr Sa
1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31

Ex for "calendar " :

student@student-cygnus ~ $ calendar
Jan 13     Horatio Alger born, 1834
Jan 13     Sophie Tucker born, 1884
Jan 13     Wilhelm Wien born, 1864, Nobel prize for blackbody radiation laws
Jan 13     National Liberation Day in Togo
.
.
.

Jan 14 Albert Schweitzer born, 1875
Jan 14 Julian Calendar New Year's Day
.
.

For more info see man page of calendar

--
Regards,
Tha.Suresh

Cooool Linux Tips & Tricks,
http://gnutips.wordpress.com

My experiences with Linux are here,
http://thasulinux.wordpress.com
 

Other related posts: