asset

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	TypeMCP = Type{
		Key:         "mcp",
		Label:       "MCP Server",
		Description: "Model Context Protocol server",
	}
	TypeMCPRemote = Type{
		Key:         "mcp-remote",
		Label:       "Remote MCP",
		Description: "Remote Model Context Protocol server configuration",
	}
	TypeSkill = Type{
		Key:         "skill",
		Label:       "Skill",
		Description: "Reusable AI skill",
	}
	TypeAgent = Type{
		Key:         "agent",
		Label:       "Agent",
		Description: "AI agent configuration",
	}
	TypeCommand = Type{
		Key:         "command",
		Label:       "Command",
		Description: "Slash command",
	}
	TypeHook = Type{
		Key:         "hook",
		Label:       "Hook",
		Description: "Git hook script",
	}
	TypeClaudeCodePlugin = Type{
		Key:         "claude-code-plugin",
		Label:       "Claude Code Plugin",
		Description: "Claude Code plugin with bundled assets",
	}
)

Functions

This section is empty.

Types

type Asset

type Asset struct {
	Name    string
	Version string
	Type    Type
	Config  map[string]string // Type-specific config (e.g., marketplace for plugins)
}

Asset represents a simple asset with just name, version, and type

type Type

type Type struct {
	Key         string
	Label       string
	Description string
}

Type represents the type of asset (skill, command, agent, etc.)

func AllTypes

func AllTypes() []Type

AllTypes returns all defined asset types

func FromString

func FromString(key string) Type

FromString creates a Type from a string key

func (Type) IsValid

func (t Type) IsValid() bool

IsValid checks if the asset type is valid

func (Type) MarshalText

func (t Type) MarshalText() ([]byte, error)

MarshalText implements encoding.TextMarshaler for TOML/JSON serialization

func (Type) String

func (t Type) String() string

String returns the string representation (key) of the asset type

func (*Type) UnmarshalText

func (t *Type) UnmarshalText(text []byte) error

UnmarshalText implements encoding.TextUnmarshaler for TOML/JSON deserialization

Jump to

Keyboard shortcuts

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