What Dave and Dave said is good advice.

You can force "-" as a filename in the POSIX world with  "./-".

On Mon, 5 Feb 2007, Fargusson.Alan wrote:
> The use of a dash as a filename is from a time when there was
> no /dev/fd/0 or /dev/stdin.  I don't recommend using that convention
> in a new program.

Depends on how widely you want the app used.
If just Linux, then maybe.  Otherwise, there's really
nothing wrong with the  "dash means stdin"  methodology.

The rest of these are really good,  specifically:

> For reading from a file:
>       mycmd -f filename
>
> Note that the filename can be /dev/stdin or /dev/fd/0
>
> For command line arguments:
>       mycmd -c "the command"
>
> You could use the following to read from stdin:
>       mycmd -s

Either that or  "-i"  (for "interactive").

-- R;

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to