files

package
v4.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindFiles

func FindFiles(ctx context.Context, where []string, fn func(absPath string), opts ...FinderOption) error

FindFiles finds all files in the given locations (without duplicates). Important note - for the direct files' extension checking will be ignored. TODO fn should returns bool (shouldStop)

Types

type FinderOption

type FinderOption func(*finderOptions)

FinderOption is a function that can be used to modify the finder options.

func WithFilesExt

func WithFilesExt(filesExt ...string) FinderOption

WithFilesExt sets the file extensions (WITHOUT leading dot) to the finder options.

func WithRecursive

func WithRecursive(recursive bool) FinderOption

WithRecursive sets the recursive option to true.

Jump to

Keyboard shortcuts

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