filesystem

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DirectoryExists

func DirectoryExists(dirName string) error

func FileExists

func FileExists(filename string) bool

Types

type FileCache

type FileCache struct {
	FileResults map[string]FileResult `yaml:"file_results"`
	// contains filtered or unexported fields
}

func NewFileCache

func NewFileCache(fileName string) *FileCache

func (*FileCache) FindFilesBySuffix

func (fc *FileCache) FindFilesBySuffix(root, fileSuffix string) ([]string, error)

func (*FileCache) LoadResultsFromYAML

func (fc *FileCache) LoadResultsFromYAML() (map[string]FileResult, error)

func (*FileCache) SaveResultsAsYAML

func (fc *FileCache) SaveResultsAsYAML(fileSuffix string, files []string) error

type FileResult

type FileResult struct {
	Query string   `yaml:"query"`
	Paths []string `yaml:"paths"`
}

Jump to

Keyboard shortcuts

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