blob: c6eec0b231d8b65c185daa0ac41372be795a8aef (
plain)
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
|
package main
import (
"bufio"
"flag"
"fmt"
"os"
"github.com/Shugyousha/stasher/conf"
)
func main() {
var configpath *string
configpath = flag.String("c", "stasher.cfg", "Path to config file")
flag.Parse()
f, err := os.Open(*configpath)
if err != nil {
fmt.Fprintf(os.Stderr, "Could not open config file %q: %q\n", *configpath, err)
os.Exit(1)
}
m := conf.NewManagerFromConfig(bufio.NewReader(f))
fmt.Fprintf(os.Stderr, "manager: %#v\n", m)
m.Run()
}
|