syntax

syntax

Synopsis
syntax lists all aliases that have a defined syntax
syntax --load | -l loads the syntax for an alias from a file
syntax --dump | -d dumps the syntax for an alias to standard output
syntax --dump-all dumps all syntaxes to standard output
syntax --remove | -r alias remove the syntax for the alias
Details
The syntax command allows you to override the built-in syntaxes for commands that use the new command syntax mechanism. The command can "dump" a command's current syntax specification as XML, and "load" a new one from an XML file. It can also "remove" a syntax, provided that the syntax was defined or overridden in the command shell's syntax manager.

The built-in syntax for a command is typically specified in the plugin descriptor for a parent plugin of the command class. If there is no explicit syntax specification, a default one will be created on-the-fly from the command's registered arguments.

Note: not all classes use the new syntax mechanism. Some JNode command classes use an older mechanism that is being phased out. Other command classes use the classic Java approach of decoding arguments passed via a "public static void main(String[])" entry point.

Bugs
The XML produced by "--dump" or "--dump-all" should be pretty-printed to make it more readable / editable.