中文
← Errors

F_SYSTEM_INVALID_TOKEN

Invalid command or option token

A command, option, alias, flag, or path token is empty, starts with a hyphen, or contains whitespace.

Updated 2 weeks ago

Reproduction

Decorator tokens describe the logical name, so they must not include CLI hyphens or whitespace:

src/build.command.ts
import { Command } from 'func'

@Command({ name: '-build' })
class BuildCommand {}

How to fix it

Pass the token without leading hyphens and use one non-whitespace segment:

src/build.command.ts
@Command({ name: 'build' })
class BuildCommand {}