helpers

package
v0.0.0-...-07af6e5 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadConfig

func LoadConfig(files []string, format string, recursively bool) (*v4.Config, error)

LoadConfig load config files to *conf.Config, it will: - resolve folder to files - try to read stdin if no file specified

func LoadConfigToMap

func LoadConfigToMap(files []string, format string, recursively bool) (map[string]interface{}, error)

LoadConfigToMap load config files to map, it will: - resolve folder to files - try to read stdin if no file specified

func ReadDir

func ReadDir(dir string, extensions []string) ([]string, error)

ReadDir finds files according to extensions in the dir

func ReadDirRecursively

func ReadDirRecursively(dir string, extensions []string) ([]string, error)

ReadDirRecursively finds files according to extensions in the dir recursively

func ResolveFolderToFiles

func ResolveFolderToFiles(paths []string, extensions []string, recursively bool) ([]string, error)

ResolveFolderToFiles expands folder path (if any and it exists) to file paths. Any other paths, like file, even URL, it returns them as is.

Types

This section is empty.

Jump to

Keyboard shortcuts

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