globset

package
v0.85.0-pre.13 Latest Latest
Warning

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

Go to latest
Published: May 8, 2026 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Rule

type Rule struct {
	Raw          string
	Pattern      string
	ChildPattern string
	Excluded     bool
	DirOnly      bool
	Anchored     bool
	HasGlob      bool
}

func Parse

func Parse(raw_rule string) (Rule, bool, error)

func (Rule) HasSegment

func (rule Rule) HasSegment(name string) bool

type Rules

type Rules []Rule

func (Rules) Compile

func (rules Rules) Compile() *Set

type Set

type Set struct {
	// contains filtered or unexported fields
}

func Compile

func Compile(raw_rules []string) (*Set, error)

func MustCompile

func MustCompile(raw_rules []string) *Set

func (*Set) Match

func (s *Set) Match(path string) bool

func (*Set) Rules

func (s *Set) Rules() Rules

Jump to

Keyboard shortcuts

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