config

package
v0.3.8 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnsureConfigDir

func EnsureConfigDir() error

func GetConfigDir

func GetConfigDir() string

func GetDefaultConfigPath

func GetDefaultConfigPath() string

func SaveConfig

func SaveConfig(cfg *Config, path string) error

Types

type Config

type Config struct {
	Identity struct {
		Name        string
		StoragePath string
	}

	Interfaces []struct {
		Name        string
		Type        string
		Enabled     bool
		ListenPort  int
		ListenIP    string
		KissFraming bool
		I2PTunneled bool
	}

	Transport struct {
		AnnounceInterval   int
		PathRequestTimeout int
		MaxHops            int
		BitrateLimit       int64
	}

	Logging struct {
		Level string
		File  string
	}
}

func InitConfig

func InitConfig() (*Config, error)

func LoadConfig

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

Jump to

Keyboard shortcuts

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