cron_test

command module
v0.0.0-...-79e6a3c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 21, 2016 License: Apache-2.0 Imports: 2 Imported by: 0

README

cron_test

cron is a crontab in golang(just a library)

Source code: github.com/robfig/cron

//every 5 second run a job
var spec5s = "0-59/5 * * * * *"

st := &stat{
	mac: 1000,
}

c.AddJob(spec5s, st)
//every day(00:00:00) run a job
var specday = "0 0 0 1-31 * *"

day := &day{
	id: 9000,
}

c.AddJob(specday, day)
Run as a daemon service

nohup cron_test >test.log 2>&1 &

Reference Paper

1.http://blog.studygolang.com/tag/cron/

2.http://ju.outofmemory.cn/entry/65356

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址