Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/alecthomas/kong
/ functions
Functions
778 in github.com/alecthomas/kong
⨍
Functions
778
◇
Types & classes
240
↓ 1 callers
Function
checkMissingChildren
(node *Node)
context.go:1134
↓ 1 callers
Function
checkMissingFlags
(flags []*Flag)
context.go:1065
↓ 1 callers
Function
checkMissingPositionals
If we're missing any positionals and they're required, return an error.
context.go:1178
↓ 1 callers
Function
checkOverlappingXorAnd
(k *Kong)
kong.go:181
↓ 1 callers
Function
checkPassthroughArg
(target reflect.Value)
context.go:1238
↓ 1 callers
Function
checkXorDuplicatedAndAndMissing
(paths []*Path)
context.go:1248
↓ 1 callers
Function
checkXorDuplicates
(paths []*Path)
context.go:1262
↓ 1 callers
Function
collectCommandGroups
(nodes []*Node)
help.go:342
↓ 1 callers
Function
collectFlagGroups
(flags [][]*Flag)
help.go:290
↓ 1 callers
Function
counterMapper
()
mapper.go:800
↓ 1 callers
Function
durationDecoder
()
mapper.go:332
↓ 1 callers
Method
endParsing
()
context.go:478
↓ 1 callers
Function
existingDirMapper
(r *Registry)
mapper.go:694
↓ 1 callers
Function
existingFileMapper
(r *Registry)
mapper.go:658
↓ 1 callers
Function
exitCodeFromError
exitCodeFromError returns the exit code for the given error. If err implements the exitCoder interface, the ExitCode method is called. Otherwise, exit
exit.go:23
↓ 1 callers
Method
extraFlags
Provide additional builtin flags, if any.
kong.go:293
↓ 1 callers
Function
fileContentMapper
(r *Registry)
mapper.go:728
↓ 1 callers
Function
fileMapper
(r *Registry)
mapper.go:627
↓ 1 callers
Method
filterLastWins
filterLastWins removes trace occurrences overridden by a later occurrence of another flag in the same lastwins group, as if they had never been given.
context.go:127
↓ 1 callers
Method
findNode
(key reflect.Value)
model.go:80
↓ 1 callers
Function
flagChoiceGroups
(flag *Flag)
context.go:1054
↓ 1 callers
Function
flattenedFields
(v reflect.Value, ptag *Tag)
build.go:56
↓ 1 callers
Function
floatDecoder
(bits int)
mapper.go:432
↓ 1 callers
Function
formatEnvs
(envs []string)
help.go:580
↓ 1 callers
Function
formatFlag
haveShort will be true if there are short flags present at all in the help. Useful for column alignment.
help.go:502
↓ 1 callers
Function
getExplicitMethod
(value reflect.Value, name string)
callbacks.go:131
↓ 1 callers
Method
getMethods
(value reflect.Value, name string)
kong.go:389
↓ 1 callers
Function
getRequiredAndGroupMap
(flags []*Flag)
context.go:1122
↓ 1 callers
Function
getValidators
getValidators returns validators implemented by v and by any embedded fields, matching how hooks are discovered (see getMethods).
context.go:1359
↓ 1 callers
Function
guessWidth
(w io.Writer)
guesswidth.go:7
↓ 1 callers
Function
handle
Handle a single SSH interactive connection.
_examples/server/main.go:22
↓ 1 callers
Function
handlerWithError
(handle func(log *log.Logger, s ssh.Session) error)
_examples/server/main.go:115
↓ 1 callers
Method
head
()
kong.go:212
↓ 1 callers
Function
intDecoder
(bits int)
mapper.go:374
↓ 1 callers
Function
isExplicitMethod
(t reflect.Type, name string)
callbacks.go:141
↓ 1 callers
Function
isNil
(v reflect.Value)
callbacks.go:240
↓ 1 callers
Function
isUnknownFlagError
(err error)
context.go:941
↓ 1 callers
Function
isValidatable
(v reflect.Value)
context.go:1341
↓ 1 callers
Function
lastWinsPeers
lastWinsPeers maps each member of a lastwins group to the other members of its group. Groups are scoped to the node their flags are declared on.
context.go:182
↓ 1 callers
Function
levenshtein
Copied from https://github.com/daviddengcn/go-algs/blob/fe23fabd9d0670e4675326040ba7c285c7117b4c/ed/ed.go#L31 License: https://github.com/daviddengcn/
levenshtein.go:7
↓ 1 callers
Function
mapDecoder
(r *Registry)
mapper.go:462
↓ 1 callers
Function
maybeGetSignature
(t reflect.Type)
tag.go:433
↓ 1 callers
Method
maybeSelectDefault
End of the line, check for a default command, but only if we're not displaying help, otherwise we'd only ever display the help for the default command
context.go:726
↓ 1 callers
Function
min
(a, b int)
levenshtein.go:34
↓ 1 callers
Function
newFunctionBinding
newFunctionBinding builds a binding with a function that will return a value of the target type. The function signature must be func(...) (T, error)
callbacks.go:38
↓ 1 callers
Method
parseFlag
(flags []*Flag, match string)
context.go:874
↓ 1 callers
Function
parseStructTagItems
(tag reflect.StructTag)
tag.go:170
↓ 1 callers
Function
parseTag
(parent reflect.Value, ft reflect.StructField)
tag.go:214
↓ 1 callers
Function
parseTagString
(s string)
tag.go:199
↓ 1 callers
Function
pathMapper
(r *Registry)
mapper.go:592
↓ 1 callers
Method
pop
()
kong.go:213
↓ 1 callers
Function
printApp
(w *helpWriter, app *Application)
help.go:142
↓ 1 callers
Function
printCommand
(w *helpWriter, app *Application, cmd *Command)
help.go:158
↓ 1 callers
Function
printCommandSummary
(w *helpWriter, cmd *Command)
help.go:373
↓ 1 callers
Method
push
(vars Vars)
kong.go:214
↓ 1 callers
Function
reflectValueIsZero
This is directly from the Go 1.13 source code.
model.go:490
↓ 1 callers
Function
removeIgnored
(fields []flattenedField, ignored map[string]bool)
build.go:119
↓ 1 callers
Method
selectedValues
selectedValues returns the set of values attached to nodes on the traced command path.
context.go:466
↓ 1 callers
Function
siftStrings
(ss []string, filter func(s string) bool)
options.go:506
↓ 1 callers
Function
snakeCase
(name string)
resolver.go:65
↓ 1 callers
Function
timeDecoder
()
mapper.go:355
↓ 1 callers
Method
trace
nolint:maintidx
context.go:494
↓ 1 callers
Function
uintDecoder
(bits int)
mapper.go:403
↓ 1 callers
Function
urlMapper
()
mapper.go:854
↓ 1 callers
Function
validatePositionalArguments
(node *Node)
build.go:238
↓ 1 callers
Function
visitNodeChildren
(node *Node, visitor Visitor)
visit.go:36
↓ 1 callers
Function
writeCommandList
(cmds []*Node, iw *helpWriter)
help.go:248
↓ 1 callers
Function
writeCommandTree
(w *helpWriter, node *Node)
help.go:271
↓ 1 callers
Function
writeCompactCommandList
(cmds []*Node, iw *helpWriter)
help.go:260
↓ 1 callers
Function
writeFlags
(w *helpWriter, groups [][]*Flag)
help.go:445
↓ 1 callers
Function
writePositionals
(w *helpWriter, args []*Positional)
help.go:437
Method
AfterApply
This is not the correct signature - see README for details.
hooks.go:24
Method
AfterApply
(ctx *hookContext)
kong_test.go:657
Method
AfterApply
(ctx *hookContext)
kong_test.go:672
Method
AfterApply
(cli *cliWithHook)
kong_test.go:1237
Method
AfterApply
(ctx *kong.Context)
kong_test.go:1247
Method
AfterApply
()
kong_test.go:3105
Method
AfterApply
()
kong_test.go:3116
Method
AfterApply
()
kong_test.go:3125
Method
AfterApply
()
kong_test.go:3136
Method
AfterApply
()
kong_test.go:3168
Method
AfterApply
()
kong_test.go:3192
Method
AfterApply
()
kong_test.go:3223
Method
AfterApply
()
kong_test.go:3250
Method
AfterRun
This is not the correct signature - see README for details. AfterRun is called after Run() returns.
hooks.go:31
Method
AfterRun
()
kong_test.go:3059
Method
Apply
Apply options to Kong as a configuration option.
help.go:71
Method
Apply
(k *Kong)
options.go:23
Method
Apply
Apply lets Vars act as an Option.
options.go:31
Method
Apply
(k *Kong)
options.go:363
Method
Apply
Apply traced context to the target grammar.
context.go:846
Method
Apply
(k *kong.Kong)
kong_test.go:2352
Method
BeforeApply
This is not the correct signature - see README for details.
hooks.go:18
Method
BeforeApply
(ctx *hookContext)
kong_test.go:652
Method
BeforeApply
(ctx *hookContext)
kong_test.go:667
Method
BeforeApply
(app *kong.Kong, vars kong.Vars)
_examples/docker/main.go:27
Method
BeforeReset
(ctx *Context)
help.go:21
Method
BeforeReset
This is not the correct signature - see README for details.
hooks.go:6
Method
BeforeReset
BeforeReset writes the version variable and terminates with a 0 exit status.
util.go:33
Method
BeforeResolve
This is not the correct signature - see README for details.
hooks.go:12
← previous
next →
201–300 of 778, ranked by callers