util

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: May 13, 2025 License: MPL-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddEnvOfServiceParam

func AddEnvOfServiceParam(cmd *cobra.Command, id *string)

func AddEnvParam

func AddEnvParam(cmd *cobra.Command, id *string)

AddEnvParam todo: support name

func AddProjectParam

func AddProjectParam(cmd *cobra.Command, id, name *string)

func AddServiceParam

func AddServiceParam(cmd *cobra.Command, id, name *string)

func GetProjectByName

func GetProjectByName(config config.Config, client api.Client, projectName string) (project *model.Project, err error)

func GetServiceByName

func GetServiceByName(config config.Config, client api.Client, serviceName string) (service *model.Service, err error)

func PackZip

func PackZip() ([]byte, string, error)

func PackZipWithoutGitIgnoreFiles

func PackZipWithoutGitIgnoreFiles() ([]byte, error)

Types

type CobraRunE

type CobraRunE func(cmd *cobra.Command, args []string) error

func DefaultIDByContext

func DefaultIDByContext(basicInfo zcontext.BasicInfo, id *string) CobraRunE

func DefaultIDNameByContext

func DefaultIDNameByContext(basicInfo zcontext.BasicInfo, id, name *string) CobraRunE

func NeedProjectContextWhenNonInteractive

func NeedProjectContextWhenNonInteractive(f *cmdutil.Factory) CobraRunE

NeedProjectContextWhenNonInteractive checks if the project context is set in the non-interactive mode

func RunEChain

func RunEChain(chains ...CobraRunE) CobraRunE

RunEChain runs a chain of CobraRunE functions

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL