mirror of
https://github.com/1f349/tulip.git
synced 2024-11-15 16:21:40 +00:00
20 lines
387 B
Go
20 lines
387 B
Go
|
package main
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
"flag"
|
||
|
"github.com/google/subcommands"
|
||
|
"os"
|
||
|
)
|
||
|
|
||
|
func main() {
|
||
|
subcommands.Register(subcommands.HelpCommand(), "")
|
||
|
subcommands.Register(subcommands.FlagsCommand(), "")
|
||
|
subcommands.Register(subcommands.CommandsCommand(), "")
|
||
|
subcommands.Register(&serveCmd{}, "")
|
||
|
|
||
|
flag.Parse()
|
||
|
ctx := context.Background()
|
||
|
os.Exit(int(subcommands.Execute(ctx)))
|
||
|
}
|