-
Notifications
You must be signed in to change notification settings - Fork 8
/
main.go
43 lines (35 loc) · 751 Bytes
/
main.go
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
32
33
34
35
36
37
38
39
40
41
42
43
package main
import (
"fmt"
"os"
"github.com/CharlesDardaman/blueskyfirehose/firehose"
cli "github.com/urfave/cli/v2"
)
func main() {
run(os.Args)
}
func run(args []string) {
app := cli.App{
Name: "firehose",
Usage: "simple firehose client for bluesky",
Version: "0.2",
}
app.Flags = []cli.Flag{
&cli.StringFlag{
Name: "pds-host",
Usage: "method, hostname, and port of PDS instance",
Value: "https://bsky.social",
EnvVars: []string{"ATP_PDS_HOST"},
},
&cli.StringFlag{
Name: "auth",
Usage: "path to JSON file with ATP auth info",
Value: "bsky.auth",
EnvVars: []string{"ATP_AUTH_FILE"},
},
}
app.Commands = []*cli.Command{
firehose.Firehose,
}
fmt.Println(app.Run(args))
}