config

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2026 License: MIT Imports: 4 Imported by: 0 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 DefaultDir

func DefaultDir() (string, error)

func DefaultPath

func DefaultPath() (string, error)

func ResolveAIKey

func ResolveAIKey(cfg *Config, flagKey string) string

func ResolveEmbeddingKey added in v0.0.6

func ResolveEmbeddingKey(cfg *Config, flagKey string) string

func ResolveToken

func ResolveToken(cfg *Config, flagToken string) string

Types

type AIConfig

type AIConfig struct {
	BaseURL      string `yaml:"base_url"`
	APIKey       string `yaml:"api_key"`
	Model        string `yaml:"model"`
	Concurrency  int    `yaml:"concurrency"`
	CustomPrompt string `yaml:"custom_prompt"`
}

type Config

type Config struct {
	GitHub    GitHubConfig    `yaml:"github"`
	AI        AIConfig        `yaml:"ai"`
	Embedding EmbeddingConfig `yaml:"embedding"`
	Generate  GenerateConfig  `yaml:"generate"`
	TUI       TUIConfig       `yaml:"tui"`
}

func Default

func Default() *Config

func Load

func Load(path string) (*Config, error)

type EmbeddingConfig added in v0.0.6

type EmbeddingConfig struct {
	BaseURL string `yaml:"base_url"`
	APIKey  string `yaml:"api_key"`
	Model   string `yaml:"model"`
}

type GenerateConfig

type GenerateConfig struct {
	Sort string `yaml:"sort"`
}

type GitHubConfig

type GitHubConfig struct {
	Token    string `yaml:"token"`
	Username string `yaml:"username"`
}

type PreviewConfig added in v0.0.17

type PreviewConfig struct {
	Open     bool    `yaml:"open"`
	Position string  `yaml:"position"`
	Width    float64 `yaml:"width"`
	Height   float64 `yaml:"height"`
}

type StarsKeybindings added in v0.1.0

type StarsKeybindings struct {
	Sync       string `yaml:"sync"`
	Analyze    string `yaml:"analyze"`
	ToggleStar string `yaml:"toggle_star"`
	EditCat    string `yaml:"edit_category"`
	EditTag    string `yaml:"edit_tag"`
}

type TUIConfig added in v0.0.17

type TUIConfig struct {
	Preview     PreviewConfig  `yaml:"preview"`
	DefaultView string         `yaml:"default_view"`
	ConfirmQuit bool           `yaml:"confirm_quit"`
	Theme       string         `yaml:"theme"`
	Keybindings TUIKeybindings `yaml:"keybindings"`
}

type TUIKeybindings added in v0.1.0

type TUIKeybindings struct {
	Universal UniversalKeybindings `yaml:"universal"`
	Stars     StarsKeybindings     `yaml:"stars"`
}

type UniversalKeybindings added in v0.1.0

type UniversalKeybindings struct {
	Quit          string `yaml:"quit"`
	Refresh       string `yaml:"refresh"`
	Search        string `yaml:"search"`
	Command       string `yaml:"command"`
	ToggleSidebar string `yaml:"toggle_sidebar"`
	Help          string `yaml:"help"`
}

Jump to

Keyboard shortcuts

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