From 02e6a8b9ae3596ee1c405cdd1541c5cc59b50e3a Mon Sep 17 00:00:00 2001 From: Horus3 Date: Thu, 19 Feb 2015 13:30:54 +0100 Subject: Static file handling and autoimport the db-driver from Makefile. --- app/fetch.go | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'app/fetch.go') diff --git a/app/fetch.go b/app/fetch.go index 27aa628..cd8206b 100644 --- a/app/fetch.go +++ b/app/fetch.go @@ -1,9 +1,17 @@ package main -/* import ( "fmt" + "github.com/robfig/cron" + "time" ) -func -*/ +func run() { + c := cron.New() + c.AddFunc("@every 1m", printStatus) + c.Start() +} + +func printStatus() { + fmt.Println(time.Now()) +} -- cgit v1.2.3