lookup

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package lookup owns the YAML description maps and eager initialization for all embedded text lookups.

Index

Constants

This section is empty.

Variables

View Source
var (
	// CommandsMap maps command description keys to their YAML entries.
	CommandsMap map[string]commandEntry

	// FlagsMap maps flag description keys to their YAML entries.
	FlagsMap map[string]commandEntry

	// TextMap maps general text description keys to their YAML entries.
	TextMap map[string]commandEntry

	// ExamplesMap maps example description keys to their YAML entries.
	ExamplesMap map[string]commandEntry
)

Functions

func Init

func Init()

Init loads all embedded YAML description maps. Call once from main() before building the command tree. Tests that need descriptions must call Init() in their setup.

func PermAllowListDefault

func PermAllowListDefault() []string

PermAllowListDefault returns the default allow permissions for ctx commands and skills, parsed from the embedded permissions/allow.txt.

func PermDenyListDefault

func PermDenyListDefault() []string

PermDenyListDefault returns the default deny permissions that block dangerous operations, parsed from the embedded permissions/deny.txt.

func StopWords

func StopWords() map[string]bool

StopWords returns the default set of stop words for keyword extraction.

Returns:

  • map[string]bool: Set of lowercase stop words

func TextDesc

func TextDesc(name string) string

Types

type ConfigPattern

type ConfigPattern struct {
	Pattern string
	Topic   string
}

ConfigPattern pairs a glob pattern with its localizable topic description.

func ConfigPatterns

func ConfigPatterns() []ConfigPattern

ConfigPatterns returns config file patterns with resolved topic descriptions.

Jump to

Keyboard shortcuts

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