.de AB
.s3
.ti -3
..
.TH Concept : COMMAND SYNTAX
.s1
The Empire command interpreter, (shell), expects input in the form:
.EX VERB ARG1 ARG2 ...
VERB is any one of the command words in "command list",
("map", "move", "info", etc).
.s1
The ARGs will vary from command to command, but certain basic
argument types recur often and are abbreviated in the following
ways.
.in 6
.AB
(cname) ::= country name
.AB
(cno) ::= country number
.AB
(item) ::= any one (or unambiguous abbreviation) of:
.NF
efficiency	minerals	gold (mineral)
mobility	production	checkpoint
defended	contracted	civilians
military	shells		guns
planes		ore		bars (of gold)
.FI
.AB
(loan) ::= loan number
.AB
(sect) ::= sector coordinates in the form:   x,y
.AB
.ne 4
(sects) ::= sector(s) in the form:
.s3
.ti +8
lox:hix,loy:hiy ?cond&cond&...
.s3
.in +2
"lox", "hix", "loy", "hiy" are coordinates bounding
the rectangular area to be considered
.s3
"cond" is a condition of the form:
.s3
.ti +8
(value)(operator)(value)
.s3
(value) is either an (item), as above,
a number in the range 0 to 127,
or a sector designation,
("m" for mine, "c" for capitol, etc),
.br
(operator) can be any one of "<", "=", ">" or "#",
.s3
Thus "mob>100", "ore#0", "7=guns", "civ<mil", "des=b" are examples
of legitimate conditions, (note lack of imbedded spaces),
and "census -3:3,-3:3 ?des=+&gun=5&mil>civ"
will list all highways
within 3 of your capital
with exactly 5 guns and more military than civilians.
.sp
Note that "hix", "hiy", and "?cond" are all optional.
Also, the entire "lox:hix,loy:hiy" section may be replaced by
either "#", "#0", "#1", "#2", or "#3" which refer to the four
"realm"s that you can define.
(See "info realm".)
Note that "#" and "#0" are equivalent.
.AB
(ship) ::= one ship number
.AB
(fleet) ::= fleet designation, which may be a single ship,
a list of ships separated by slashes, `/', a fleet letter,
the character `~' which means all ships not in a specific fleet,
or a rectangular sector area.
.sp
Note that (fleet) specifications may have an optional ?cond&cond...
argument like that used for (sects) arguments.
In the case of ships either "civ" or "mil" may be used for the "crew"
of a ship and "designation" is used for ship type.
For instance, "ship ~ ?des=d&mil>5", will list all destroyers not currently
in any fleet with more than 5 crew.

.in 0
.sp 2
.ne 2
The output from commands may also be sent to a file or another
process by utilizing these alternate syntaxes:
.ne 2
.EX VERB ARG1 ARG2 ... >FILE
which sends the output both to the terminal and the file "FILE".
.ne 2
.EX VERB ARG1 ARG2 ... >>FILE
which sends the output to the terminal and appends it to the file "FILE".
.ne 2
.EX VERB ARG1 ARG2 ... | PROG ARG1 ARG2 ...
which sends the output to the terminal and to the program "PROG" along with
the specified arguments, (which can also include redirection of output
or further piping).
.sp 2
The Empire shell also recognizes a few control characters:
.nf
name        code    meaning
----        ----    -------
interrupt   <DEL>   Abort command and return to Empire command level
quit        ^\\      Exit Empire
EOT         ^D      Exit Empire
.fi
.sp
See also: realm, command
.in \\n(in
