File: postinst

package info (click to toggle)
anacron 2.0.1-2
  • links: PTS
  • area: main
  • in suites: hamm, slink
  • size: 188 kB
  • ctags: 161
  • sloc: ansic: 1,091; makefile: 98; sh: 53
file content (34 lines) | stat: -rw-r--r-- 803 bytes parent folder | download
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
32
33
34
#!/bin/sh

case "$1" in
    configure)
        # continue below
    ;;

    abort-upgrade|abort-remove|abort-deconfigure)
        exit 0
    ;;

    *)
        echo "postinst called with unknown argument \`$1'" >&2
        exit 0
    ;;
esac

echo "Creating links in /etc/rc?.d directories ..."
/usr/sbin/update-rc.d anacron defaults >/dev/null

# Does /etc/crontab contain an entry to run anacron?
if grep -q -e '^[^#]*anacron' /etc/crontab; then
    # yes.

    echo
    echo "This version of the anacron package registers its cron job"
    echo "through the /etc/cron.d/anacron file. Therefore, your /etc/crontab"
    echo "file should _NOT_ contain a job to run anacron."
    echo
    echo "It's suggested that you remove this job."
    echo
    echo "Press <Return> to continue..."
    read ans
fi