file

package
Version: v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2020 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RootDir = "/"

RootDir is used to determine where to run from. Default is of course "/", but this can be changed to read from a captured set of files.

Functions

func Exists

func Exists(file string) bool

Exists if a file exists.

func ListDirsWithRegex

func ListDirsWithRegex(basePath string, regularExpression string) []string

ListDirsWithRegex returns a list of directories meeting a specific regular expression.

func ParseKeyValue

func ParseKeyValue(target string, delimiter string) map[string]string

ParseKeyValue parses a key value file with a specified delimiter.

func Read

func Read(file string) string

Read a file and return value as string.

func ReadInt

func ReadInt(file string) int

ReadInt a file and return value as an int.

func ReadInt64

func ReadInt64(file string) int64

ReadInt64 a file and return value as an int64.

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

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