
Некоторые проверки провалились
test / test (1.16.x) (push) Has been cancelled
test / test (1.17.x) (push) Has been cancelled
26 строки
488 Б
Go
26 строки
488 Б
Go
package internal
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
"git.golang1.ru/softonik/godog"
|
|
)
|
|
|
|
// CreateVersionCmd creates the version subcommand.
|
|
func CreateVersionCmd() cobra.Command {
|
|
versionCmd := cobra.Command{
|
|
Use: "version",
|
|
Short: "Show current version",
|
|
Run: versionCmdRunFunc,
|
|
Version: godog.Version,
|
|
}
|
|
|
|
return versionCmd
|
|
}
|
|
|
|
func versionCmdRunFunc(cmd *cobra.Command, args []string) {
|
|
fmt.Fprintln(os.Stdout, "Godog version is:", godog.Version)
|
|
}
|