Browse Source

better printout

pull/2427/head
Chris Lu 3 years ago
parent
commit
ab97b17e62
  1. 2
      weed/command/shell.go
  2. 4
      weed/shell/shell_liner.go

2
weed/command/shell.go

@ -46,8 +46,6 @@ func runShell(command *Command, args []string) bool {
}
if cluster == "" {
*shellOptions.Masters = "localhost:9333"
fmt.Printf("master: %s\n", *shellOptions.Masters)
} else {
*shellOptions.Masters = v.GetString("cluster." + cluster + ".master")
*shellInitialFiler = v.GetString("cluster." + cluster + ".filer")

4
weed/shell/shell_liner.go

@ -65,10 +65,12 @@ func RunShell(options ShellOptions) {
}
return nil
})
fmt.Printf("master: %s ", *options.Masters)
if len(filers) > 0 {
fmt.Printf("filers: %v\n", filers)
fmt.Printf("filers: %v", filers)
commandEnv.option.FilerAddress = filers[rand.Intn(len(filers))]
}
fmt.Println()
}
if commandEnv.option.FilerAddress != "" {

Loading…
Cancel
Save