doublestar

package
v0.8.6 Latest Latest
Warning

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

Go to latest
Published: May 28, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Glob

func Glob(base, pattern string, ignore IgnoreFunc) ([]string, error)

Glob finds all files that match the pattern and not the ignore func

func Match

func Match(pattern, path string) (matches bool, err error)

Match matches the same patterns as filepath.Match except it can also match an arbitrary number of path segments using **

Types

type IgnoreFunc

type IgnoreFunc func(path string) bool

IgnoreFunc checks if a path ought to be ignored

var IgnoreNone IgnoreFunc = func(path string) bool { return false }

IgnoreNone ignores nothing

func IgnoreStrings

func IgnoreStrings(ignores []string) IgnoreFunc

IgnoreStrings ignores all paths which contain one of the ignores substrings

Jump to

Keyboard shortcuts

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