abstract class fanc::FancCmd
sys::Obj util::AbstractMain fanc::FancCmd
Fantom CLI compiler command plugin. To create:
- Define subclass of FancCmd
- Register type qname via indexed prop as "fanc.cmd" (if not in this pod)
- Annotate options and args using
AbstractMain
design
- aliases
-
virtual Str[] aliases()
Command name alises/shortcuts
- appName
-
override Str appName()
App name is "fanc {name}"
- err
-
Print error message and return 1
- find
-
static FancCmd? find(Str name)
Find a specific command or return null
- info
-
Print info message
- list
-
static FancCmd[] list()
List installed commands
- log
-
virtual override Log log()
Log name is "fanc"
- name
-
abstract Str name()
Command name
- names
-
Str[] names()
Name and aliases
- printLine
-
Void printLine(Str line := "")
Print a line to stdout
- promptConfirm
-
Prompt for a confirm yes/no
- run
-
abstract override Int run()
Run the command. Return zero on success
- summary
-
abstract Str summary()
Single line summary of the command for help