INNER CODE UNIT · Go

main

docker/cli · e2e/cli-plugins/plugins/presocket/main.go:16

func main() {
	plugin.Run(RootCmd, metadata.Metadata{
		SchemaVersion: "0.1.0",
		Vendor:        "Docker Inc.",
		Version:       "test",
	})
}

func RootCmd(dockerCli command.Cli) *cobra.Command {
	cmd := cobra.Command{
		Use:   "presocket",
		Short: "testing plugin that does not connect to the socket",
		// override PersistentPreRunE so that the plugin default
		// PersistentPreRunE doesn't run, simulating a plugin built
		// with a pre-socket-communication version of the CLI
		PersistentPreRunE: func(cmd *cobra.Command, args []string) error {
			return nil
		},

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…