From 612c9d3d632fd64d97dcf87ac4b2af71b2d19c86 Mon Sep 17 00:00:00 2001 From: gorhill Date: Thu, 29 Aug 2013 15:05:08 -0400 Subject: [PATCH] README.md --- README.md | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9055cb3..b1ae6e2 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,24 @@ gocronexpression ================ -Go language (golang) cron expression parser. Given a cron expression and a time stamp, you can get the next time stamp which satisfy the cron expression +Go language (golang) cron expression parser. Given a cron expression and a time stamp, you can get the next time stamp which satisfy the cron expression. + +Install +------- + + go get github.com/gorhill/cronexpression + +Usage +----- + +Import the library: + + import "github.com/gorhill/cronexpression" + import "time" + +Simplest way: + + ... + nextTime := cronexpression.NextTimeFromCronString("* * 29 2 *", time.Now()) + +Assuming *time.Now()* is "2013-08-29 09:28:00", then *nextTime* will be "Monday, February 29, 2016 00:00:00".