tags

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package tags provides functionality for managing tool tags and filtering.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IncludeTags

type IncludeTags struct {
	// Include is a list of tags to include.
	Include Tags
	// Exclude is a list of tags to exclude.
	Exclude Tags
}

IncludeTags is a struct that defines the tags to include or exclude.

type Tags

type Tags []string

Tags represents a list of tags associated with a tool. Tags can be used to categorize or filter tools based on specific labels or keywords.

func (*Tags) Append

func (t *Tags) Append(tags ...string)

Append adds new tags to the Tags list, avoiding duplicates.

func (Tags) Exclude

func (t Tags) Exclude(tags Tags) bool

Exclude checks if none of the provided tags are present in the Tags list. Returns true if none of the tags match.

func (Tags) Include

func (t Tags) Include(tags Tags) bool

Include checks if any of the provided tags are present in the Tags list. Returns true if at least one tag matches.

func (*Tags) UnmarshalYAML

func (t *Tags) UnmarshalYAML(node ast.Node) (err error)

UnmarshalYAML implements custom unmarshaling for Tags, allowing the field to be either a single string or a list of strings.

Jump to

Keyboard shortcuts

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