1.0.7 • Published 6 years ago

fabottimer v1.0.7

Weekly downloads
1
License
ISC
Repository
-
Last release
6 years ago

#fabottimer

사용법

루트폴더에 holiday.url 파일을 생성합니다.(휴일을 받아올 수 있는 인터넷 주소 GET 방식)

예시

/*global require, module, console*/
/*jslint this:true, for:true*/

(function () {

    'use strict';

    var Fabottimer = require('fabottimer');

    var testjob = function () {
        console.log('1');
    };

    /**
     * node-cron scheduler
     * (second(0-59), minute(0-59), hour(0-23), day of month(1-31), month(1-12), day of week(0-7 0:sun, 6:sat))
     */
    var fabottimer = new Fabottimer(); //new 항목이 추가되었음
    fabottimer.register({ //등록
        pass_holiday: false, //휴일은 건너 뛸 경우 true, 휴일에도 진행할 경우 false 입력
        func: testjob, //실행할 함수명
        time: '*/3 * * * * *' //crobjob 시간 포맷
    });
    fabottimer.start(); //실행
}());

크론잡 문법

fabottimer 에서 참조 한(node-cron)의 시간 설정 규칙입니다.

허용 되는 필드는 다음과 같습니다.

 # ┌────────────── second (optional)
 # │ ┌──────────── minute
 # │ │ ┌────────── hour
 # │ │ │ ┌──────── day of month
 # │ │ │ │ ┌────── month
 # │ │ │ │ │ ┌──── day of week
 # │ │ │ │ │ │
 # │ │ │ │ │ │
 # * * * * * *

필드 및 값

필드명
second0-59
minute0-59
hour0-23
day of month1-31
month1-12 (or names)
day of week0-7 (or names, 0 or 7 are sunday)
1.0.7

6 years ago

1.0.5

6 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago