Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Cmd = &cobra.Command{ Use: "TODO", Short: "Load tool", Args: cobra.MaximumNArgs(1), Run: func(cmd *cobra.Command, args []string) { ctx := context.Background() client, err := internal.NewMongoClient(ctx, "mongodb://localhost:27018") tracelog.ErrorLogger.FatalOnError(err) var input io.Reader input = os.Stdin if ammoFile != "" { file, err := os.Open(ammoFile) tracelog.ErrorLogger.FatalOnError(err) input = file defer func() { _ = file.Close() }() } stat, err := mongoload.HandleLoad(ctx, input, client, 1) tracelog.ErrorLogger.FatalOnError(err) err = internal.PrintStat(stat, os.Stdout) tracelog.ErrorLogger.FatalOnError(err) }, }
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.