O'Reilly logo

Mac OS X Tiger in a Nutshell by Jason McIntosh, Chuck Toporek, Chris Stone, Andy Lester

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

calendar

Synopsis

calendar [option]

Reads your calendar file and displays all lines that contain the current date. The calendar file is like a memo board. You create the file and add entries such as the following:

5/4     meeting with design group at 2 pm
may 6   pick up anniversary card on way home

When you run calendar on May 4, the first line is displayed. calendar can be automated by using crontab or at, or by including it in your startup files, .profile or .login.

Options

-A num

Print the next num days in the future, including today.

-a

Allow a privileged user to invoke calendar for all users, searching each user's login directory for a file named calendar. Entries that match are sent to a user via mail. This feature is intended for use via cron. It isn't recommended in networked environments with large user bases.

-B num

Print the previous num days in the past, including today.

-d MMDD [[YY]YY]

Display lines for the given date.

-F daynum

Specify "virtual Friday," the last day before the weekend.

-f filename

Display calendar items from file filename instead of the default calendar file in your home directory.

-l n

Display calendar items up to n days ahead from the current date as well.

-W num

Print the next num days in the future, including today, but not counting weekend days in the count.

-w n

Force calendar to skip over weekends. Display calendar items up to n days ahead from the current date only when the current day is a Friday. The default for n is 2.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required