config

package
v0.0.0-...-4e49b11 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2025 License: MIT Imports: 7 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Save

func Save(cfg *Config) (string, error)

Save returns (config file path, error)

Types

type Config

type Config struct {
	Theme ThemeConfig `json:"theme"`

	// Keys are the git repo path, e.g. "raymondji/git-stack-cli"
	Repositories map[string]RepoConfig `json:"repositories"`
}

func Load

func Load() (*Config, error)

type GithubConfig

type GithubConfig struct {
	PersonalAccessToken string `json:"personalAccessToken"`
}

type GitlabConfig

type GitlabConfig struct {
	PersonalAccessToken string `json:"personalAccessToken"`
}

type RepoConfig

type RepoConfig struct {
	DefaultBranch string       `json:"defaultBranch"`
	Gitlab        GitlabConfig `json:"gitlab"`
	Github        GithubConfig `json:"github"`
}

type Theme

type Theme struct {
	PrimaryColor    lipgloss.Style
	SecondaryColor  lipgloss.Style
	TertiaryColor   lipgloss.Style
	QuaternaryColor lipgloss.Style
}

func NewTheme

func NewTheme(cfg ThemeConfig) Theme

type ThemeConfig

type ThemeConfig struct {
	PrimaryColor    string `json:"primaryColor"`
	SecondaryColor  string `json:"secondaryColor"`
	TertiaryColor   string `json:"tertiaryColor"`
	QuaternaryColor string `json:"quarternaryColor"`
}

Jump to

Keyboard shortcuts

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