Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Danny Stringer — — source: Informix-list mailing list archive (1991-1998)
>> Why are you testing the time when it's run at a specific time from cron
>> anyway ???
>> do you not trust cron to get the time right ???
>
>Would you rather have him write two scripts?
No, the way I would do it would be to have two sections to the one script
the way
all the files in /etc/init.d do it, that way in cron you can have eg
0 10,13 * * * mybackup_script cron
and in the script have a function eg,
backup() {
...
...
}
backup_cron() {
...
...
}
case $1 in
cron) backup_cron ;;
*) backup ;;
esac
Your privacy choices
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.