Versions in this module Expand all Collapse all v0 v0.7.6 Jun 15, 2024 Changes in this version + const CmdTypeNone + const CmdTypeSimple + const CompTypeArg + const CompTypeAssignment + const CompTypeBasic + const CompTypeCommand + const CompTypeCommandMeta + const CompTypeDir + const CompTypeFile + const CompTypeInvalid + const CompTypeVar + const MaxExpandLen + const WordTypeBQ + const WordTypeDB + const WordTypeDDQ + const WordTypeDP + const WordTypeDPP + const WordTypeDQ + const WordTypeDSQ + const WordTypeGroup + const WordTypeKey + const WordTypeLit + const WordTypeOp + const WordTypePP + const WordTypeRaw + const WordTypeSQ + const WordTypeSimpleVar + const WordTypeVarBrace + func Extend(word *WordType, wordPos int, extStr string, complete bool) utilfn.StrWithPos + func ResetWordOffsets(words []*WordType, startIdx int) + func SimpleVarNamePrefix(ectx ExpandContext, word *WordType, pos int) (string, bool) + type CmdType struct + AssignmentWords []*WordType + NoneComplete bool + Type string + Words []*WordType + func ParseCommands(words []*WordType) []*CmdType + type CompletionPos struct + Cmd *CmdType + CmdWordPos int + CompType string + CompWord *WordType + CompWordOffset int + RawPos int + SuperOffset int + func FindCompletionPos(cmds []*CmdType, pos int) CompletionPos + func (cpos CompletionPos) Extend(origStr utilfn.StrWithPos, extensionStr string, extensionComplete bool) utilfn.StrWithPos + type ExpandContext struct + HomeDir string + type ExpandInfo struct + HasExtGlob bool + HasGlob bool + HasHistory bool + HasSpecial bool + HasTilde bool + HasVar bool + func SimpleExpand(ectx ExpandContext, word *WordType) (string, ExpandInfo) + func SimpleExpandPrefix(ectx ExpandContext, word *WordType, pos int) (string, ExpandInfo) + type QuoteContext []string + type WordType struct + Complete bool + Offset int + Prefix []rune + QC QuoteContext + Raw []rune + Subs []*WordType + Type string + func CommandsToWords(cmds []*CmdType) []*WordType + func MakeEmptyWord(wtype string, qc QuoteContext, offset int, complete bool) *WordType + func Tokenize(cmd string) []*WordType + func (w *WordType) String() string