2026-04-25 17:40:39 +03:00
|
|
|
package main
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"fmt"
|
|
|
|
|
"os"
|
|
|
|
|
|
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func main() {
|
|
|
|
|
if err := newRootCommand().Execute(); err != nil {
|
|
|
|
|
fmt.Fprintln(os.Stderr, err)
|
|
|
|
|
os.Exit(1)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func newRootCommand() *cobra.Command {
|
|
|
|
|
rootCmd := &cobra.Command{
|
|
|
|
|
Use: "warpbox",
|
|
|
|
|
Short: "WarpBox command line interface",
|
|
|
|
|
Long: "WarpBox provides commands for running and managing the WarpBox service.",
|
|
|
|
|
}
|
|
|
|
|
|
2026-04-30 11:31:43 +03:00
|
|
|
rootCmd.AddCommand(newRunCommand())
|
|
|
|
|
rootCmd.AddCommand(newBoxCommand())
|
|
|
|
|
rootCmd.AddCommand(newEnvCommand())
|
2026-04-25 17:40:39 +03:00
|
|
|
return rootCmd
|
|
|
|
|
}
|