-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmain.go
54 lines (44 loc) · 1.28 KB
/
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
44
45
46
47
48
49
50
51
52
53
54
package main
import (
"fmt"
"os"
"github.com/combust-labs/firebuild/cmd/baseos"
"github.com/combust-labs/firebuild/cmd/inspect"
"github.com/combust-labs/firebuild/cmd/kill"
"github.com/combust-labs/firebuild/cmd/ls"
profileCreate "github.com/combust-labs/firebuild/cmd/profiles/create"
profileInspect "github.com/combust-labs/firebuild/cmd/profiles/inspect"
profileLs "github.com/combust-labs/firebuild/cmd/profiles/ls"
"github.com/combust-labs/firebuild/cmd/purge"
"github.com/combust-labs/firebuild/cmd/rootfs"
"github.com/combust-labs/firebuild/cmd/run"
"github.com/spf13/cobra"
_ "github.com/combust-labs/firebuild/pkg/utils/randinit"
)
var rootCmd = &cobra.Command{
Use: "firebuild",
Short: "firebuild",
Long: ``,
Run: func(cmd *cobra.Command, args []string) {
cmd.Help()
os.Exit(1)
},
}
func init() {
rootCmd.AddCommand(baseos.Command)
rootCmd.AddCommand(inspect.Command)
rootCmd.AddCommand(kill.Command)
rootCmd.AddCommand(ls.Command)
rootCmd.AddCommand(profileCreate.Command)
rootCmd.AddCommand(profileInspect.Command)
rootCmd.AddCommand(profileLs.Command)
rootCmd.AddCommand(purge.Command)
rootCmd.AddCommand(rootfs.Command)
rootCmd.AddCommand(run.Command)
}
func main() {
if err := rootCmd.Execute(); err != nil {
fmt.Println(err)
os.Exit(1)
}
}