calapi/cmd/root.go
2023-02-24 22:17:45 +01:00

27 lines
582 B
Go

package cmd
import (
"os"
"github.com/spf13/cobra"
)
// rootCmd represents the base command when called without any subcommands
var rootCmd = &cobra.Command{
Use: "calapi",
Short: "Your headless calendar.",
Long: `CalAPI allows you to have a headless calendar which can be manipulated using a GraphQL-API.`,
}
// Execute adds all child commands to the root command and sets flags appropriately.
// This is called by main.main(). It only needs to happen once to the rootCmd.
func Execute() {
err := rootCmd.Execute()
if err != nil {
os.Exit(1)
}
}
func init() {
}