confighandler

package
v1.1.74-nightly Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2025 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadConfig

func ReadConfig[T any](path string) (*T, error)

func WriteConfig

func WriteConfig(path string, v interface{}, perm fs.FileMode) error

Types

type Config

type Config[T any] interface {
	Read() (*T, error)
	Write() error
}

func GetHandler

func GetHandler[T any](path string) Config[T]

Jump to

Keyboard shortcuts

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