mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-11-29 14:31:30 +08:00
28 lines
424 B
Go
28 lines
424 B
Go
|
package shell
|
||
|
|
||
|
import (
|
||
|
"github.com/chrislusf/seaweedfs/weed/wdclient"
|
||
|
"google.golang.org/grpc"
|
||
|
"io"
|
||
|
)
|
||
|
|
||
|
type ShellOptions struct {
|
||
|
Masters *string
|
||
|
GrpcDialOption grpc.DialOption
|
||
|
}
|
||
|
|
||
|
type commandEnv struct {
|
||
|
env map[string]string
|
||
|
masterClient *wdclient.MasterClient
|
||
|
}
|
||
|
|
||
|
type command interface {
|
||
|
Name() string
|
||
|
Help() string
|
||
|
Do([]string, *commandEnv, io.Writer) error
|
||
|
}
|
||
|
|
||
|
var (
|
||
|
commands = []command{}
|
||
|
)
|