pilosa: github.com/pilosa/pilosa/cmd Index | Files | Directories

package cmd

import "github.com/pilosa/pilosa/cmd"

Package cmd contains all the pilosa subcommand definitions (1 per file).

Each command file has an init function and a New*Cmd function, as well as a global exported instance of the command.

The New*Cmd function is a function which returns a cobra.Command object wrapping this subcommand.

The init function adds the New*Cmd to a map of subcommand functions which ensures that no two commands have the same name, and is used when a new root command is created to instantiate all of the subcommands.

The instance of the command is global and exported so that it can be tested.


Package Files

check.go config.go doc.go export.go generate_config.go import.go inspect.go root.go server.go


var Exporter *ctl.ExportCommand
var Importer *ctl.ImportCommand
var Server *server.Command

Server is global so that tests can control and verify it.

func NewRootCommand Uses

func NewRootCommand(stdin io.Reader, stdout, stderr io.Writer) *cobra.Command


pilosaThis is the entrypoint for the Pilosa binary.

Package cmd imports 14 packages (graph) and is imported by 5 packages. Updated 2020-01-04. Refresh now. Tools for package owners.