Documentation ¶
Overview ¶
Package cli contains the archer subcommands.
Index ¶
- Constants
- func BuildCompletionCmd() *cobra.Command
- func BuildEnvAddCmd() *cobra.Command
- func BuildEnvCmd() *cobra.Command
- func BuildEnvListCmd() *cobra.Command
- func BuildInitCmd() *cobra.Command
- func BuildProjCmd() *cobra.Command
- func BuildProjectInitCommand() *cobra.Command
- func BuildProjectListCommand() *cobra.Command
- type AddEnvOpts
- type CompletionOpts
- type InitAppOpts
- type InitProjectOpts
- type ListEnvOpts
- type ListProjectOpts
Constants ¶
const (
// EnvProjectFlag is the flag for providing the project name to the env commands.
EnvProjectFlag = "project"
)
Variables ¶
This section is empty.
Functions ¶
func BuildCompletionCmd ¶
BuildCompletionCmd returns the command to output shell completion code for the specified shell (bash or zsh).
func BuildEnvAddCmd ¶
BuildEnvAddCmd builds the command for adding an environment.
func BuildEnvCmd ¶
BuildEnvCmd is the top level command for environments
func BuildEnvListCmd ¶
BuildEnvListCmd builds the command for listing environments in a project.
func BuildInitCmd ¶
BuildInitCmd builds the command for bootstrapping an application.
func BuildProjCmd ¶
BuildProjCmd builds the top level project command and related subcommands.
func BuildProjectInitCommand ¶
BuildProjectInitCommand builds the command for creating a new project.
func BuildProjectListCommand ¶
BuildProjectListCommand builds the command to list existing projects.
Types ¶
type AddEnvOpts ¶
type AddEnvOpts struct { ProjectName string EnvName string EnvProfile string Production bool // contains filtered or unexported fields }
AddEnvOpts contains the fields to collect for adding an environment.
func (*AddEnvOpts) Ask ¶
func (opts *AddEnvOpts) Ask() error
Ask asks for fields that are required but not passed in.
func (*AddEnvOpts) Execute ¶
func (opts *AddEnvOpts) Execute() error
Execute deploys a new environment with CloudFormation and adds it to SSM.
type CompletionOpts ¶
type CompletionOpts struct { Shell string // must be "bash" or "zsh" // contains filtered or unexported fields }
CompletionOpts contains the fields needed to generate completion scripts.
func (*CompletionOpts) Execute ¶
func (opts *CompletionOpts) Execute() error
Execute writes the completion code to the writer. This method assumes that Validate() was called prior to invocation.
func (*CompletionOpts) Validate ¶
func (opts *CompletionOpts) Validate() error
Validate returns an error if the shell is not "bash" or "zsh".
type InitAppOpts ¶
type InitAppOpts struct { Project string // namespace that this application belongs to. AppName string // unique identifier for the application. AppType string // type of application you're trying to build (LoadBalanced, Backend, etc.) ShouldDeploy bool // true means we should create a test environment and deploy the application in it. Defaults to false. // contains filtered or unexported fields }
InitAppOpts holds the fields to bootstrap a new application.
func (*InitAppOpts) Ask ¶
func (opts *InitAppOpts) Ask() error
Ask prompts the user for the value of any required fields that are not already provided.
func (*InitAppOpts) Execute ¶
func (opts *InitAppOpts) Execute() error
Execute creates a project and initializes the workspace.
func (*InitAppOpts) Prepare ¶
func (opts *InitAppOpts) Prepare()
Prepare loads contextual data such as any existing projects, the current workspace, etc.
func (*InitAppOpts) Validate ¶
func (opts *InitAppOpts) Validate() error
Validate returns an error if a command line flag provided value is invalid
type InitProjectOpts ¶
type InitProjectOpts struct { ProjectName string // contains filtered or unexported fields }
InitProjectOpts contains the fields to collect for creating a project.
func (*InitProjectOpts) Execute ¶
func (opts *InitProjectOpts) Execute() error
Execute creates a new managed empty project.
type ListEnvOpts ¶
type ListEnvOpts struct { ProjectName string // contains filtered or unexported fields }
ListEnvOpts contains the fields to collect for listing an environment.
func (*ListEnvOpts) Ask ¶
func (opts *ListEnvOpts) Ask() error
Ask asks for fields that are required but not passed in.
func (*ListEnvOpts) Execute ¶
func (opts *ListEnvOpts) Execute() error
Execute lists the environments through the prompt.
type ListProjectOpts ¶
type ListProjectOpts struct {
// contains filtered or unexported fields
}
ListProjectOpts contains the fields to collect for listing a project.
func (*ListProjectOpts) Execute ¶
func (opts *ListProjectOpts) Execute() error
Execute lists the existing projects to the prompt.