mirror of
https://github.com/sablierapp/sablier.git
synced 2025-12-21 13:23:03 +01:00
23 lines
389 B
Go
23 lines
389 B
Go
package cmd
|
|
|
|
import (
|
|
"github.com/acouvreur/sablier/app"
|
|
"github.com/spf13/cobra"
|
|
"github.com/spf13/viper"
|
|
)
|
|
|
|
var newStartCommand = func() *cobra.Command {
|
|
return &cobra.Command{
|
|
Use: "start",
|
|
Short: "Start the Sablier server",
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
viper.Unmarshal(&conf)
|
|
|
|
err := app.Start(conf)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
},
|
|
}
|
|
}
|