You can run calendar whenever you like, but it might be more useful to put it in your profile file (~/.bash_profile if you use the bash shell). Then calendar will run each time you log in to the system.
I keep my personal calendar file in the doc/etc/ subdirectory of my home directory, so I would include the following line in my profile:
cd /home/m/doc/etc/; calendar; cd
Putting the same line in your .bashrc file (again, only if you use the bash shell—others are different) also works to run calendar each time you start a shell.
Sometimes even this isn't enough—if your machine is on all the time and you haven't been starting any new shells or xterms, you might miss a reminder. So you could schedule a cron job to run calendar each day, e-mailing the output to you as a reminder.
The cal program displays a text calendar. If you call it without any options by typing:
the current month will be displayed on the terminal like this (assuming September, 1998):
September 1998 S M Tu W Th F S 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 30It's pretty no-frills, but can work on any terminal. To get a calendar of the whole year, call cal with the year as argument.
cal -ywill print a calendar for the current year.
cal can also display any arbitrary month. If you want to see the month of December 1999, for instance, use:
cal 12 1999
in which case you'll see:
December 1999 S M Tu W Th F S 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
While cal is quite useful for creating simple calendars, sometimes when printing you might want a nicer output. pcal is a program that creates very nice calendars in PostScript. Its options are very similar to that of cal. It is available from http://garbo.uwasa.fi/unix/pcal.html.
Other programs that handle calendar functions in a more graphically-intense way (and can be used only in X) include ical, at http://www.research.digital.com/SRC/personal/Sanjay_Ghemawat/ical/home.html and plan, found at http://www.in-berlin.de/User/bitrot/plan.html. There are many variants of the basic UNIX calendar programs—check the Linux Software Map for more.
With this overview of the power and flexibility of these simple calendar programs, you too can leave your analog calendar systems behind.
Practical Task Scheduling Deployment
July 20, 2016 12:00 pm CDT
One of the best things about the UNIX environment (aside from being stable and efficient) is the vast array of software tools available to help you do your job. Traditionally, a UNIX tool does only one thing, but does that one thing very well. For example, grep is very easy to use and can search vast amounts of data quickly. The find tool can find a particular file or files based on all kinds of criteria. It's pretty easy to string these tools together to build even more powerful tools, such as a tool that finds all of the .log files in the /home directory and searches each one for a particular entry. This erector-set mentality allows UNIX system administrators to seem to always have the right tool for the job.
Cron traditionally has been considered another such a tool for job scheduling, but is it enough? This webinar considers that very question. The first part builds on a previous Geek Guide, Beyond Cron, and briefly describes how to know when it might be time to consider upgrading your job scheduling infrastructure. The second part presents an actual planning and implementation framework.
Join Linux Journal's Mike Diehl and Pat Cameron of Help Systems.
Free to Linux Journal readers.Register Now!
- Google's SwiftShader Released
- Interview with Patrick Volkerding
- SUSE LLC's SUSE Manager
- My +1 Sword of Productivity
- Tech Tip: Really Simple HTTP Server with Python
- Murat Yener and Onur Dundar's Expert Android Studio (Wrox)
- Non-Linux FOSS: Caffeine!
- Managing Linux Using Puppet
- SuperTuxKart 0.9.2 Released
- Returning Values from Bash Functions
With all the industry talk about the benefits of Linux on Power and all the performance advantages offered by its open architecture, you may be considering a move in that direction. If you are thinking about analytics, big data and cloud computing, you would be right to evaluate Power. The idea of using commodity x86 hardware and replacing it every three years is an outdated cost model. It doesn’t consider the total cost of ownership, and it doesn’t consider the advantage of real processing power, high-availability and multithreading like a demon.
This ebook takes a look at some of the practical applications of the Linux on Power platform and ways you might bring all the performance power of this open architecture to bear for your organization. There are no smoke and mirrors here—just hard, cold, empirical evidence provided by independent sources. I also consider some innovative ways Linux on Power will be used in the future.Get the Guide