aboutsummaryrefslogtreecommitdiff
path: root/main.go
blob: d7009ae658048982a61e9357ae24ccde88062af3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package main

import (
	"skunkyart/app"
	"skunkyart/static"
	"time"

	"git.macaw.me/skunky/devianter"
)

func main() {
	app.Release.Version = "1.3.2"
	app.Release.Description = "Two API endpoints and template embedding into binary"
	go app.RefreshInstances()

	app.ExecuteCommandLineArguments()
	app.ExecuteConfig()
	static.CopyTemplatesToMemory()

	go func() {
		for {
			err := devianter.UpdateCSRF()
			if err != nil {
				println(err.Error())
			}
			time.Sleep(12 * time.Hour)
		}
	}()

	app.Router()
}