search

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PluginSearchSource

type PluginSearchSource struct {
	Plugins []plugin.Plugin
}

PluginSearchSource implements fuzzy.Source for plugins

func (PluginSearchSource) Len

func (s PluginSearchSource) Len() int

Len returns the number of items

func (PluginSearchSource) String

func (s PluginSearchSource) String(i int) string

String returns the searchable string for item at index i

type RankedPlugin

type RankedPlugin struct {
	Plugin plugin.Plugin
	Score  int
}

RankedPlugin wraps a plugin with its search score

func Search(query string, plugins []plugin.Plugin) []RankedPlugin

Search performs fuzzy search on plugins and returns ranked results. Empty query returns all plugins sorted by installed status then name. Scoring algorithm: exact match (100), partial (70), fuzzy (0-50), keywords (30), category (15), description (25), installed boost (+5).

Jump to

Keyboard shortcuts

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