中文

Glossary

Look up CLI input, func model, and runtime terminology without mixing their layers.

Updated 2 weeks ago

These terms belong to different layers and are not interchangeable. Start with Core Concepts when learning to define a command, and use this page only when you need a precise lookup.

Ordinary CLI input terms

TermMeaningLocation or API
InvocationOne complete execution from starting the executable until it exits, such as ship project —help.complete argv
ExecutableThe program name a user enters, such as ship. package.json#bin normally points it to a built file.package.json#bin
TokenOne ordered piece of command-line input before modeling, such as project, —role, or owner.process.argv
OptionA general CLI term for —name, -n, and associated values; func divides these into field options and handler flags.@Flag / @Value / @Handler({ flag })
Positional inputData identified by its position rather than an option name, such as alice.@Args().inputs

Concepts that define a func CLI

TermMeaningAPI
Named commandThe command class selected when the first bare token matches its name or alias.@Command()
Major commandOwns invocations without a named command, including executable-only and option-first input.@CommandMajor()
Missing commandAn optional fallback class for an unmatched first positional token.@CommandMissing()
HandlerA method that performs an action inside a command class; one invocation selects one handler.@Handler()
Default handlerRuns when no handler path or handler flag matches. A command class may define at most one.@Handler()
Handler pathOne or more fixed positional tokens that select a handler; the longest matching path wins.@Handler({ path })
Handler flagAn option such as —help that switches execution to another mutually exclusive handler.@Handler({ flag, alias })
Field optionA flag, scalar value, or repeated value parsed and assigned to a command instance property.@Flag / @Value / @ArrayValue
InputPositional tokens left after removing the named command and selected handler path.FuncArgs.inputs

Runtime and application-structure terms

TermMeaningAPI
Command scopeThe one decorated class selected for an invocation: major, named, or missing.CommandMajor / Command / CommandMissing
RegistryRead-only metadata for registered named commands, most often used to generate help.@Regs() / CommandRegistry
ModuleAn application boundary that organizes commands, services, and imported modules; it is not a command.@FuncModule()
ServiceA reusable class registered by a module and injected by constructor type for domain or infrastructure work.@Service()

See Runtime for how these definitions select a class, method, and dependencies, or API Reference for every decorator parameter.