build

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package build contains types and functions for build cobra sub-command

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Command

func Command(p *params.Params, ioStreams *genericclioptions.IOStreams) *cobra.Command

Command returns Build subcommand of Shipwright CLI for interaction with shipwright builds

Types

type CreateCommand

type CreateCommand struct {
	// contains filtered or unexported fields
}

CreateCommand contains data input from user

func (*CreateCommand) Cmd

func (c *CreateCommand) Cmd() *cobra.Command

Cmd returns cobra.Command object of the create subcommand.

func (*CreateCommand) Complete

func (c *CreateCommand) Complete(params *params.Params, args []string) error

Complete fills internal subcommand structure for future work with user input

func (*CreateCommand) Run

Run executes the creation of a new Build instance using flags to fill up the details.

func (*CreateCommand) Validate

func (c *CreateCommand) Validate() error

Validate is used for user input validation of flags and other data.

type DeleteCommand

type DeleteCommand struct {
	// contains filtered or unexported fields
}

DeleteCommand contains data provided by user to the delete subcommand

func (*DeleteCommand) Cmd

func (c *DeleteCommand) Cmd() *cobra.Command

Cmd returns cobra command object of the delete subcommand

func (*DeleteCommand) Complete

func (c *DeleteCommand) Complete(params *params.Params, args []string) error

Complete fills DeleteSubCommand structure with data obtained from cobra command

func (*DeleteCommand) Run

Run contains main logic of delete subcommand

func (*DeleteCommand) Validate

func (c *DeleteCommand) Validate() error

Validate is used for validation of user input data

type ListCommand

type ListCommand struct {
	// contains filtered or unexported fields
}

ListCommand struct contains user input to the List subcommand of Build

func (*ListCommand) Cmd

func (c *ListCommand) Cmd() *cobra.Command

Cmd returns cobra command object of List subcommand

func (*ListCommand) Complete

func (c *ListCommand) Complete(params *params.Params, args []string) error

Complete fills object with user input data

func (*ListCommand) Run

Run contains main logic of List subcommand of Build

func (*ListCommand) Validate

func (c *ListCommand) Validate() error

Validate checks user input data

type RunCommand

type RunCommand struct {
	// contains filtered or unexported fields
}

RunCommand represents the `build run` sub-command, which creates a unique BuildRun instance to run the build process, informed via arguments.

func (*RunCommand) Cmd

func (r *RunCommand) Cmd() *cobra.Command

Cmd returns cobra.Command object of the create sub-command.

func (*RunCommand) Complete

func (r *RunCommand) Complete(params *params.Params, args []string) error

Complete picks the build resource name from arguments, and instantiate additional components.

func (*RunCommand) Run

func (r *RunCommand) Run(params *params.Params, ioStreams *genericclioptions.IOStreams) error

Run creates a BuildRun resource based on Build's name informed on arguments.

func (*RunCommand) Validate

func (r *RunCommand) Validate() error

Validate the user must inform the build resource name.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳