fileutils

package
v5.9.5+incompatible Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2019 License: AGPL-3.0, Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindConfigFile

func FindConfigFile(fileName string) (path string)

FindConfigFile attempts to find an existing configuration file. fileName can be an absolute or relative path or name such as "/opt/mattermost/config.json" or simply "config.json". An empty string is returned if no configuration is found.

func FindDir

func FindDir(dir string) (string, bool)

fileutils.FindDir looks for the given directory in nearby ancestors relative to the current working directory as well as the directory of the executable, falling back to `./` if not found.

func FindFile

func FindFile(path string) string

FindFile looks for the given file in nearby ancestors relative to the current working directory as well as the directory of the executable.

func FindPath

func FindPath(path string, baseSearchPaths []string, filter func(os.FileInfo) bool) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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