中文
← 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

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('-build')
class BuildCommand {}

How to fix it

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

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