all repos — legit @ f04137f841de6fefe4c79fedeb718b252a3b2958

web frontend for git

main.go (view raw)

 1package main
 2
 3import (
 4	"flag"
 5	"log"
 6	"net/http"
 7
 8	"icyphox.sh/legit/config"
 9	"icyphox.sh/legit/routes"
10)
11
12func main() {
13	var cfg string
14	flag.StringVar(&cfg, "config", "./config.yaml", "path to config file")
15	flag.Parse()
16
17	c, err := config.Read(cfg)
18	if err != nil {
19		log.Fatal(err)
20	}
21
22	mux := routes.Handlers(c)
23	log.Fatal(http.ListenAndServe(":5555", mux))
24}