config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ConfigFileName is the name of the config file
	ConfigFileName = ".ahrefsrc"
)

Variables

This section is empty.

Functions

func GetAPIKey

func GetAPIKey() string

GetAPIKey gets the API key from config, env var, or returns empty string

func Save

func Save(cfg *Config) error

Save saves the configuration to file

Types

type Config

type Config struct {
	APIKey string `json:"api_key"`
}

Config represents the CLI configuration

func Load

func Load() (*Config, error)

Load loads the configuration from file

Jump to

Keyboard shortcuts

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