Versions in this module Expand all Collapse all v0 v0.12.0 Mar 9, 2026 v0.11.0 Mar 2, 2026 Changes in this version + const DefaultDirMode + const DefaultFileMode + var DefaultRegistry = NewRegistry() + func AdapterNames() []string + func Convert(data []byte, from, to string) ([]byte, error) + func Register(adapter Adapter) + func WriteCanonicalFile(cmd *Command, path string) error + func WriteCommandsToDir(commands []*Command, dir string, adapterName string) error + type Adapter interface + DefaultDir func() string + FileExtension func() string + Marshal func(cmd *Command) ([]byte, error) + Name func() string + Parse func(data []byte) (*Command, error) + ReadFile func(path string) (*Command, error) + WriteFile func(cmd *Command, path string) error + func GetAdapter(name string) (Adapter, bool) + type Argument struct + Default string + Description string + Hint string + Name string + Pattern string + Required bool + Type string + type Command struct + Arguments []Argument + Dependencies []string + Description string + Examples []Example + Instructions string + Name string + Process []string + func NewCommand(name, description string) *Command + func ParseCommandMarkdown(data []byte) (*Command, error) + func ReadCanonicalDir(dir string) ([]*Command, error) + func ReadCanonicalFile(path string) (*Command, error) + func (c *Command) AddArgument(arg Argument) + func (c *Command) AddDependency(dep string) + func (c *Command) AddExample(description, input, output string) + func (c *Command) AddOptionalArgument(name, description, defaultValue string) + func (c *Command) AddProcessStep(step string) + func (c *Command) AddRequiredArgument(name, description, hint string) + type Example struct + Description string + Input string + Output string + type MarshalError struct + Err error + Format string + func (e *MarshalError) Error() string + func (e *MarshalError) Unwrap() error + type ParseError struct + Err error + Format string + Path string + func (e *ParseError) Error() string + func (e *ParseError) Unwrap() error + type ReadError struct + Err error + Path string + func (e *ReadError) Error() string + func (e *ReadError) Unwrap() error + type Registry struct + func NewRegistry() *Registry + func (r *Registry) AdapterNames() []string + func (r *Registry) Convert(data []byte, from, to string) ([]byte, error) + func (r *Registry) GetAdapter(name string) (Adapter, bool) + func (r *Registry) Register(adapter Adapter) + type WriteError struct + Err error + Path string + func (e *WriteError) Error() string + func (e *WriteError) Unwrap() error