commands

package
v0.1.30 Latest Latest
Warning

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

Go to latest
Published: May 31, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SubmitText          = runtimecommands.SubmitText
	SubmitLocalReadOnly = runtimecommands.SubmitLocalReadOnly
	SubmitLocalUI       = runtimecommands.SubmitLocalUI
	SubmitLocalMode     = runtimecommands.SubmitLocalMode
	SubmitLocalMutating = runtimecommands.SubmitLocalMutating
	SubmitExit          = runtimecommands.SubmitExit
	SubmitTurnStarting  = runtimecommands.SubmitTurnStarting
	SubmitUsageError    = runtimecommands.SubmitUsageError
)

Variables

This section is empty.

Functions

func AskPromptFromSlash

func AskPromptFromSlash(line string) (string, bool)

func CommandsHelp

func CommandsHelp() string

func ExpandUniqueSlashPrefix

func ExpandUniqueSlashPrefix(line, help string, localCommands ...string) string

func IsOpenCommandLine

func IsOpenCommandLine(line string) bool

func LooksLikeSlashCommand

func LooksLikeSlashCommand(line string) bool

func NewSessionID

func NewSessionID(now time.Time) string

func ParseSlashCommands

func ParseSlashCommands(help string) []string

func PlanPromptFromSlash

func PlanPromptFromSlash(line string) (string, bool)

func ReviewPromptFromArgs

func ReviewPromptFromArgs(args string) (string, error)

func ReviewShellAllowPrefixesFromArgs

func ReviewShellAllowPrefixesFromArgs(args string) ([]string, error)

func SlashCommandNames

func SlashCommandNames(localCommands ...string) []string

Types

type Result

type Result struct {
	Handled            bool
	ShouldExit         bool
	ClearScreen        bool
	SessionID          string
	Output             string
	ShowStatus         bool
	Mode               string
	AskPrompt          string
	PlanPrompt         string
	InitMemory         bool
	ShowSkills         bool
	ReviewPrompt       string
	AllowShellPrefixes []string
	ForkName           string
	BtwQuestion        string
}

func Parse

func Parse(line, currentSessionID string, now time.Time) (Result, error)

type SlashCommandOption

type SlashCommandOption = runtimecommands.SlashCommandOption

type SlashCommandSpec

type SlashCommandSpec = runtimecommands.SlashCommandSpec

func DefaultSlashCommands

func DefaultSlashCommands() []SlashCommandSpec

type SubmitClass

type SubmitClass = runtimecommands.SubmitClass

type SubmitClassification

type SubmitClassification = runtimecommands.SubmitClassification

func ClassifySubmit

func ClassifySubmit(line, help string, localCommands ...string) SubmitClassification

Jump to

Keyboard shortcuts

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