Skip to content

Latest commit

 

History

History
31 lines (24 loc) · 718 Bytes

README.md

File metadata and controls

31 lines (24 loc) · 718 Bytes

Reloader

Build Status Coverage Release

Library for automatic reloading configuration files based on file system events.

Using

package main

import (
	"log"
	"time"

	"github.com/aandryashin/reloader"
)

func loadConfig() {
	//...
}

func main() {
	err := reloader.Watch("config", loadConfig, 5*time.Second)
	if err != nil {
		log.Fatal(err)
	}
	//...
}