Ticket #43 (new enhancement)

Opened 2 years ago

Last modified 1 year ago

op Feature request: Optional Parameters

Reported by: athomas Assigned to: athomas
Priority: major Component: op
Severity: normal Keywords:
Cc:

Description

We would like to be able to specify that a command could have 1 or 2 parameters.

For example, this configuration requires that 2 parameters be specified:

prtvtoc /usr/sbin/prtvtoc $1 $2;

This one won't allow a second parameter:

prtvtoc /usr/sbin/prtvtoc $1;

I'd like to be able to allow users to specify either 1 or 2 parameters. e.g. the following should both be acceptable:

  • prtvtoc /dev/rdsk/c1t0d0s2
  • prtvtoc -h /dev/rdsk/c1t0d0s2

Perhaps with a syntax like this:

prtvtoc /usr/sbin/prtvtoc $1 $2?;

or this:

prtvtoc /usr/sbin/prtvtoc $1 [$2];

Attachments

Change History

04/20/07 11:28:56 changed by anonymous

  • component changed from DevTodo to op.

Add/Change #43 (op Feature request: Optional Parameters)




Change Properties
Action