filter

package
v0.99.0 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Filter

func Filter(values []string, regex *regexp.Regexp, opts ...Option) ([]string, error)

Types

type Option

type Option interface {
	// contains filtered or unexported methods
}

func ExcludeOlderThan added in v0.99.0

func ExcludeOlderThan(age time.Duration) Option

ExcludeOlderThan excludes files whose modification time is older than the specified age.

func SortAlphabetical

func SortAlphabetical(regexKey string, ascending bool) (Option, error)

func SortMtime added in v0.89.0

func SortMtime() Option

func SortNumeric

func SortNumeric(regexKey string, ascending bool) (Option, error)

func SortTemporal

func SortTemporal(regexKey string, ascending bool, layout string, location string) (Option, error)

Jump to

Keyboard shortcuts

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