UPDATE

From ICE Enterprises
Jump to navigation Jump to search

Updates the command.cnf file for a specified option tree

<NAME>  The name of the command to be added/updated.

Keyword Only Parameters

[OPT]     The name of the option tree where the command runs.
[SUPPORT] The support type (M:macro, I:intrinsic, P:primitive, N:native
                            H:X-Midas primitive)
[NARGS]  The number of arguments this command accepts.
[DEF][1...N] The default parameter values.

Update accepts the above arguments to use when updating or adding a command to
the commands.cnf file.  If any of the values are not specified on the  command
line they will be prompted for.   When updating an existing command -  the
current values for that command will be displayed as the initial values,  which
the user can override.

NOTE: H support is for Fortran primitives run with the XBC file.

Details:

The command line is parsed to determine which values have been specified. The
user will be prompted for those values not specified.  The commands.cnf file for
the specified option tree is searched to see if the command currently exists.
If so, that command will be updated with the new information. Otherwise the new
command will be added to the file.  The NAME parameter can contain an "*" symbol
to indicate an accepted abbreviation for that command. The NARGS command can
have a "+" symbol following the number to indicate that the number specified is
the minimum number of arguments it will accept.

When prompted for the command arguments, a dash (-) can be entered to remove a
KEY=VAL parameter.

The UPDATE utility automatically calls CONFIGURE and PATH REDO whenever you
update a command.

Examples:

  * To add a command and be prompted for the command parameters:
      nM> update mynewcommand

  * To add a command to the commands.cnf file
      nM> update name=calculator* opt=sys support=I nargs=2+ DEF1="LABEL=ANSWER"

  * To update a command
      nM> update name=calc*ulator opt=sys support=I nargs=1+ DEF1="LABEL=ANSWER"

  * To delete a command
      nM> update/delete name=calculator opt=sys


Switches:
  /AUTO    Updates without prompting. This is equivalent to supplying all
           arguments.
  /DELETE  Removes a command from the COMMANDS.CNF file without prompting.

SEE ALSO:  CONFIGURE, PATH