plugin

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: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Author

type Author struct {
	Name    string `json:"name"`
	Email   string `json:"email"`
	URL     string `json:"url"`
	Company string `json:"company"`
}

Author represents plugin author information

type Plugin

type Plugin struct {
	Name              string   `json:"name"`
	Description       string   `json:"description"`
	Version           string   `json:"version"`
	Keywords          []string `json:"keywords"`
	Category          string   `json:"category"`
	Author            Author   `json:"author"`
	Marketplace       string   `json:"-"`      // Friendly marketplace name (e.g., "feedmob-plugins")
	MarketplaceRepo   string   `json:"-"`      // Full repo URL for display (e.g., "https://github.com/feed-mob/claude-code-marketplace")
	MarketplaceSource string   `json:"-"`      // CLI source format (e.g., "feed-mob/claude-code-marketplace" for GitHub)
	Installed         bool     `json:"-"`      // Whether this plugin is currently installed
	IsDiscoverable    bool     `json:"-"`      // Whether from a discoverable (not installed) marketplace
	InstallPath       string   `json:"-"`      // Path if installed
	Source            string   `json:"source"` // Source path within marketplace
	Homepage          string   `json:"homepage"`
	Repository        string   `json:"repository"` // Source repository URL
	License           string   `json:"license"`    // License identifier (e.g., "MIT")
	Tags              []string `json:"tags"`       // Categorization tags
}

Plugin represents a Claude Code plugin from any marketplace. Contains metadata, installation state, and marketplace source information. Used for search, display, and installation command generation.

func (Plugin) AuthorName

func (p Plugin) AuthorName() string

AuthorName returns the author's name or "Unknown" if not set

func (Plugin) FilterValue

func (p Plugin) FilterValue() string

FilterValue implements the list.Item interface for bubbles/list

func (Plugin) FullName

func (p Plugin) FullName() string

FullName returns the plugin identifier in format "name@marketplace"

func (Plugin) GitHubURL added in v0.3.0

func (p Plugin) GitHubURL() string

GitHubURL returns the GitHub URL for this plugin's source code Constructs URL from MarketplaceRepo + Source path Example: https://github.com/owner/repo/tree/main/plugins/plugin-name

func (Plugin) InstallCommand

func (p Plugin) InstallCommand() string

InstallCommand returns the command to install this plugin

func (Plugin) Title

func (p Plugin) Title() string

Title implements the list.DefaultItem interface

func (*Plugin) UnmarshalJSON added in v0.3.3

func (p *Plugin) UnmarshalJSON(data []byte) error

UnmarshalJSON implements custom JSON unmarshaling for Plugin to handle the "source" field which can be either a string or an object with Git URL.

Jump to

Keyboard shortcuts

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