Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
// Env is the environment the CLI is running in
Env = "DEV"
)
View Source
var GetConfigDir = func() (string, error) { homeDir, err := os.UserHomeDir() if err != nil { return "", err } return filepath.Join(homeDir, configDir), nil }
Functions ¶
func SaveGlobalConfig ¶ added in v1.4.0
func SaveGlobalConfig(globalConfig GlobalConfig) error
func SetupConfigDir ¶
func SetupConfigDir() error
Types ¶
type Credential ¶ added in v1.2.9
type GlobalConfig ¶ added in v1.4.0
type GlobalConfig struct {
OrganizationID string `json:"organization_id"`
ProjectID string `json:"project_id"`
Credential Credential `json:"credential"`
KnownProjects []KnownProject `json:"known_projects"`
// the following are not saved in json
CurrRepoKnown bool `json:"-"` // when true, the current repo and path are already in known_projects
CurrRepoURL string `json:"-"`
CurrRepoPath string `json:"-"`
}
func GetGlobalConfig ¶ added in v1.4.0
func GetGlobalConfig() (GlobalConfig, error)
Click to show internal directories.
Click to hide internal directories.