| // Copyright 2015 The Go Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style |
| // license that can be found in the LICENSE file. |
| "golang.org/x/build/buildlet" |
| func destroy(args []string) error { |
| fs := flag.NewFlagSet("destroy", flag.ContinueOnError) |
| fmt.Fprintln(os.Stderr, "destroy usage: gomote destroy <instance>") |
| // List buildlets that you might want to destroy. |
| cc, err := buildlet.NewCoordinatorClientFromFlags() |
| rbs, err := cc.RemoteBuildlets() |
| fmt.Printf("possible instances:\n") |
| fmt.Printf("\t%s\n", rb.Name) |
| bc, err := remoteClient(name) |