config

package
v0.22.3 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ManifestConfigFile = ".hx"
	ManifestSecretFile = ".hxkey"
)

Functions

func AddAppToLocalProject

func AddAppToLocalProject(appDir string) error

func ExistsInFolder

func ExistsInFolder(folder string) bool

func ExistsLocal

func ExistsLocal() bool

func GetGlobalDirectory

func GetGlobalDirectory() string

func GlobalInitializeConfig

func GlobalInitializeConfig(mc Config) error

func InitializeConfig

func InitializeConfig(mc Config, configFile string) error

func UpsertGlobalConfig

func UpsertGlobalConfig(mc Config) error

func UpsertGlobalOrganizationID

func UpsertGlobalOrganizationID(organizationID string) error

func UpsertGlobalProject added in v0.17.0

func UpsertGlobalProject(project models.Project) error

func UpsertLocalWorkspace

func UpsertLocalWorkspace(workspace ConfigProject) error

func UpsertOrganizationID

func UpsertOrganizationID(organizationID string) error

func UpsertProject added in v0.17.0

func UpsertProject(project models.Project) error

Types

type Config

type Config struct {
	ProjectName        *string        `json:"project_name,omitempty"`
	ProjectId          *string        `json:"project_id,omitempty"`
	ProjectAlternateId *string        `json:"project_alternate_id,omitempty"`
	AppName            *string        `json:"app_name,omitempty"`
	AppId              *string        `json:"app_id,omitempty"`
	AppAlternateId     *string        `json:"app_alternate_id,omitempty"`
	OrganizationId     string         `json:"organization_id,omitempty"`
	HyphenAccessToken  *string        `json:"hyphen_access_token,omitempty"`
	HyphenRefreshToken *string        `json:"hyphen_refresh_token,omitempty"`
	HypenIDToken       *string        `json:"hyphen_id_token,omitempty"`
	ExpiryTime         *int64         `json:"expiry_time,omitempty"`
	HyphenAPIKey       *string        `json:"hyphen_api_key,omitempty"`
	IsMonorepo         *bool          `json:"is_monorepo,omitempty"`
	Project            *ConfigProject `json:"project,omitempty"`
	Database           interface{}    `json:"database,omitempty"`
}

func RestoreConfig

func RestoreConfig() (Config, error)

func RestoreConfigFromFile

func RestoreConfigFromFile(manifestConfigFile string) (Config, error)

func RestoreGlobalConfig

func RestoreGlobalConfig() (Config, error)

func RestoreLocalConfig

func RestoreLocalConfig() (Config, error)

func (*Config) IsMonorepoProject

func (c *Config) IsMonorepoProject() bool

type ConfigProject added in v0.17.0

type ConfigProject struct {
	Apps []string `json:"app"`
}

func (*ConfigProject) AddApp added in v0.17.0

func (w *ConfigProject) AddApp(appDir string)

Jump to

Keyboard shortcuts

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