Skip to content

Instantly share code, notes, and snippets.

@TheRedDev
TheRedDev / crontab_header.sh
Last active July 4, 2024 23:18 — forked from wesleyit/crontab_header.sh
A default crontab header that will make the life easier for those who don't remember cron fields or keywords.
## Disable E-mail notifications
#MAILTO=""
## Set where to look for executable files
#PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/sbin:/usr/local/bin:$PATH
##
## Entry Equivalent Description
## @yearly 0 0 1 1 * Run once a year at midnight in the morning of January 1
## @annually 0 0 1 1 * Run once a year at midnight in the morning of January 1
## @monthly 0 0 1 * * Run once a month at midnight in the morning of the first of the month
## @weekly 0 0 * * 0 Run once a week at midnight in the morning of Sunday
var Logger = function(enable, prefix) {
this.log = {};
if ((typeof globalEnableLogger !== 'undefined' && globalEnableLogger == false) || enable == false) {
for(var m in console) {
if(typeof console[m] == 'function') {
this.log[m] = function(){};
}
}
} else if (enable && typeof enable === 'string') {
for (var m in console) {