Documentation
¶
Overview ¶
Package cli implements the command-line interface for ctx.
Index ¶
- Variables
- func Execute()
- func GetConfigManager() (*config.Manager, error)
- func GetShellConfigFile(shellType shell.ShellType) string
- func NewCloudClient(mgr interface{ ... }) *cloud.Client
- func NewRootCmd() *cobra.Command
- func OpenBrowser(cfg *config.BrowserConfig) error
- func OpenEditor(cfg *config.EditorConfig) error
- func OpenEditorFile(cfg *config.EditorConfig, file string) error
- func OpenURL(cfg *config.BrowserConfig, url string) error
- type SecretFilesResult
- type SecretsResult
Constants ¶
This section is empty.
Variables ¶
View Source
var (
// Version is set at build time.
Version = "dev"
)
Functions ¶
func GetConfigManager ¶
GetConfigManager returns the config manager, initializing it if needed.
func GetShellConfigFile ¶
GetShellConfigFile returns the path to the shell config file.
func NewCloudClient ¶ added in v0.1.3
func NewCloudClient(mgr interface {
GetAppConfig() *config.AppConfig
LoadCloudAPIKey() string
}) *cloud.Client
NewCloudClient creates a cloud client from the config manager. Returns nil if cloud integration is not configured or disabled.
func OpenBrowser ¶
func OpenBrowser(cfg *config.BrowserConfig) error
OpenBrowser opens the browser with the context's configured profile (no URL).
func OpenEditor ¶ added in v0.1.9
func OpenEditor(cfg *config.EditorConfig) error
OpenEditor opens the workspace in the configured editor.
func OpenEditorFile ¶ added in v0.1.9
func OpenEditorFile(cfg *config.EditorConfig, file string) error
OpenEditorFile opens a specific file in the configured editor.
Types ¶
type SecretFilesResult ¶ added in v0.1.7
type SecretFilesResult struct {
EnvVars map[string]string // ENV_VAR -> temp file path
State *config.SecretFilesState
FileCount int
}
SecretFilesResult holds the results of resolving secret files.
Click to show internal directories.
Click to hide internal directories.