Calendar (cal) on Linux command line - Comment Page: 1
Sometimes it feels that many of the excellent and convenient command-line tools is forgotten, when they are replaced by graphical tools. A good example is the cal program, which is a command-line calendar to Linux and UNIX. It displays a simple calendar in text format.
Cal usage:
Displays current month calendar on console:
cal
Output:
October 2009
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
Displays selected month and year calendar on console:
cal 11 2012
Output:
November 2012
Su Mo Tu We Th Fr Sa
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16...
thanks for this, its a nice tool
cal -m -y does not working…..yyy…whats wrong with that
Hi chinnu,
Try following instead:
cal -m -y 2012 works with older versions of cal. I update this guide too.
i wnted to display only the last 6 months of the calender
is there any command for that please help…??
Late response, and this is sort of cheating, but it’s not horribly complicated to just run it in a loop in your shell like so:
for m in 7 8 9 10 11 12; do cal $m 2013; done
cal -B5 does the trick :)
i want to use only business days in a script to check for files availability on every month on BD-11
plz help is any command for this ?