提交 c1e4dd19 编写于 作者: LinuxSuRen's avatar LinuxSuRen

Show the current jenkins in the root cmd

上级 9517785f
......@@ -21,6 +21,13 @@ var rootCmd = &cobra.Command{
Run: func(cmd *cobra.Command, args []string) {
fmt.Println("Jenkins CLI (jcli) manage your Jenkins")
current := getCurrentJenkins()
if current != nil {
fmt.Println("Current Jenkins is:", current.Name)
} else {
fmt.Println("Cannot found the configuration")
}
if rootOptions.Version {
fmt.Printf("Version: v%.2f.%d%s", app.CurrentVersion.Number,
app.CurrentVersion.PatchLevel,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册