functions

package
v0.0.0-...-c0b29db Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: BSD-3-Clause Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const TooFewArguments = "Too few arguments"

Variables

View Source
var Table = map[string]func([]interface{}) []interface{}{
	"access":             CmdAccess,
	"atou":               CmdAtoU,
	"atou_if_needed":     CmdAnsiToUtf8IfNeeded,
	"bitand":             CmdBitAnd,
	"bitor":              CmdBitOr,
	"chdir":              CmdChdir,
	"commonprefix":       CmdCommonPrefix,
	"complete_for_files": CmdCompleteForFiles,
	"dirname":            CmdDirName,
	"elevated":           CmdElevated,
	"envadd":             CmdEnvAdd,
	"envdel":             CmdEnvDel,
	"fields":             CmdFields,
	"getenv":             CmdGetEnv,
	"gethistory":         CmdGetHistory,
	"getkey":             CmdGetKey,
	"getkeys":            CmdGetKeys,
	"getviewwidth":       CmdGetViewWidth,
	"getwd":              CmdGetwd,
	"glob":               CmdGlob,
	"pathjoin":           CmdPathJoin,
	"resetcharwidth":     CmdResetCharWidth,
	"setenv":             CmdSetEnv,
	"setrunewidth":       CmdSetRuneWidth,
	"shellexecute":       CmdShellExecute,
	"skk":                CmdSkk,
	"stat":               CmdStat,
	"utoa":               CmdUtoA,
	"which":              CmdWhich,
}
View Source
var Table2 = map[string]func(*Param) []interface{}{
	"box":            CmdBox,
	"raweval":        CmdRawEval,
	"rawexec":        CmdRawExec,
	"write":          CmdWrite,
	"writerr":        CmdWriteErr,
	"default_prompt": Prompt,
}

Functions

func CmdAccess

func CmdAccess(args []any) []any

func CmdAnsiToUtf8IfNeeded

func CmdAnsiToUtf8IfNeeded(args []any) []any

func CmdAtoU

func CmdAtoU(args []any) []any

func CmdBitAnd

func CmdBitAnd(args []any) []any

func CmdBitOr

func CmdBitOr(args []any) []any

func CmdBitXor

func CmdBitXor(args []any) []any

func CmdBox

func CmdBox(this *Param) []any

func CmdChdir

func CmdChdir(args []any) []any

func CmdCommonPrefix

func CmdCommonPrefix(args []any) []any

func CmdCompleteForFiles

func CmdCompleteForFiles(args []any) []any

func CmdDirName

func CmdDirName(args []any) []any

func CmdElevated

func CmdElevated([]any) []any

func CmdEnvAdd

func CmdEnvAdd(args []any) []any

func CmdEnvDel

func CmdEnvDel(args []any) (result []any)

func CmdFields

func CmdFields(args []any) []any

func CmdGetBindKey

func CmdGetBindKey(args []any) []any

CmdGetBindKey is the getter for nyagos.key table.

func CmdGetEnv

func CmdGetEnv(args []any) []any

func CmdGetHistory

func CmdGetHistory(args []any) []any

func CmdGetKey

func CmdGetKey(args []any) []any

func CmdGetKeys

func CmdGetKeys(args []any) []any

func CmdGetViewWidth

func CmdGetViewWidth(args []any) []any

func CmdGetwd

func CmdGetwd(args []any) []any

func CmdGlob

func CmdGlob(args []any) []any

func CmdLenHistory

func CmdLenHistory(args []any) []any

func CmdMsgBox

func CmdMsgBox(args []any) []any

func CmdPathJoin

func CmdPathJoin(args []any) []any

func CmdPrint

func CmdPrint(this *Param) []any

func CmdRawEval

func CmdRawEval(this *Param) []any

func CmdRawExec

func CmdRawExec(this *Param) []any

func CmdResetCharWidth

func CmdResetCharWidth(args []any) []any

func CmdSetEnv

func CmdSetEnv(args []any) []any

func CmdSetRuneWidth

func CmdSetRuneWidth(args []any) []any

func CmdShellExecute

func CmdShellExecute(args []any) []any

func CmdSkk

func CmdSkk(args []any) []any

func CmdStat

func CmdStat(args []any) []any

func CmdUtoA

func CmdUtoA(args []any) []any

func CmdWhich

func CmdWhich(args []any) []any

func CmdWrite

func CmdWrite(this *Param) []any

func CmdWriteErr

func CmdWriteErr(this *Param) []any

func CmdWriteSub

func CmdWriteSub(this *Param, out io.Writer) []any

func GetOption

func GetOption(args []any) []any

func Prompt

func Prompt(param *Param) []interface{}

Prompt is the body of the lua-function `nyagos.default_prompt`

func PromptCore

func PromptCore(console io.Writer, args ...interface{}) string

PromptCore prints prompt-str(args[0]) to console.

func SetOption

func SetOption(args []any) []any

Types

type Param

type Param struct {
	Args []interface{}
	In   io.Reader
	Out  io.Writer
	Err  io.Writer
	Term io.Writer
}

Param is the parameter type for nyagos.xxxxxx which uses stdin/stdout/stderr/colored-console.

Jump to

Keyboard shortcuts

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