xref: /freebsd/usr.sbin/periodic/etc/daily/300.calendar (revision f81cdf24ba5436367377f7c8e8f51f6df2a75ca7)
1#!/bin/sh
2#
3#
4# `calendar -a' needs to die. Why? Because it's a bad idea, particular
5# with networked home directories, but also in general.  If you want the
6# output of `calendar' mailed to you, set up a cron job to do it,
7# or run it from your ~/.profile or ~/.login.
8#
9
10# If there is a global system configuration file, suck it in.
11#
12if [ -r /etc/defaults/periodic.conf ]
13then
14    . /etc/defaults/periodic.conf
15    source_periodic_confs
16fi
17
18case "$daily_calendar_enable" in
19    [Yy][Ee][Ss])
20	echo ""
21	echo "Running calendar:"
22
23	calendar -a && rc=0 || rc=3;;
24
25    *)  rc=0;;
26esac
27
28exit $rc
29