Documentation
¶
Index ¶
- Constants
- Variables
- func AddCommands(rootCmd *cobra.Command)
- func FindGitPathAndURL() (string, string, error)
- func GetCurrentConfig() (globalconfig.GlobalConfig, error)
- func GetCurrentConfigWithContext(ctx context.Context) (*globalconfig.GlobalConfig, error)
- func InitForge()
- func NewTeaProgram(model tea.Model, opts ...tea.ProgramOption) *tea.Program
- type User
Constants ¶
View Source
const ( DeploymentTypeDeploy = "deploy" DeploymentTypeDestroy = "destroy" DeploymentTypeReset = "reset" DeploymentStatusFailed = "failed" DeploymentStatusPassed = "passed" )
View Source
const MaxProjectNameLen = 50
View Source
const (
RetryBaseDelay time.Duration = 100 * time.Millisecond
)
Variables ¶
View Source
var ForgeCmd = &cobra.Command{ Use: "forge", Short: "Forge is a tool for managing World Forge projects", RunE: func(cmd *cobra.Command, _ []string) error { if !checkLogin() { return nil } globalConfig, err := GetCurrentConfig() if err != nil { return eris.Wrap(err, "Failed to get user") } fmt.Println("✨ World Forge Status ✨") fmt.Println("=====================") fmt.Println("\n👤 User Information") fmt.Println("------------------") fmt.Printf("ID: %s\n", globalConfig.Credential.ID) fmt.Printf("Name: %s\n", globalConfig.Credential.Name) err = showOrganizationList(cmd.Context()) if err == nil { _ = showProjectList(cmd.Context()) } fmt.Println("\n================================================") return cmd.Help() }, }
Functions ¶
func AddCommands ¶ added in v1.6.0
func FindGitPathAndURL ¶ added in v1.7.0
func GetCurrentConfig ¶ added in v1.7.0
func GetCurrentConfig() (globalconfig.GlobalConfig, error)
func GetCurrentConfigWithContext ¶ added in v1.7.0
func GetCurrentConfigWithContext(ctx context.Context) (*globalconfig.GlobalConfig, error)
func NewTeaProgram ¶ added in v1.4.1
NewTeaProgram will create a BubbleTea program that automatically sets the no input option if you are not on a TTY, so you can run the debugger. Call it just as you would call tea.NewProgram().
Types ¶
Click to show internal directories.
Click to hide internal directories.