Question about GETOPT(3)

Keith Gabryelski ag at amix.commodore.com
Sun Nov 19 15:03:10 AEST 1989


In article <7043 at ficc.uu.net> peter at ficc.uu.net (Peter da Silva) writes:
>What syntax should the shell use for /dev/stdin?
>	command &1		# stdout is an argument to command.

'&' in the shell is an actual separator of commands, that is:

	command1 & command2

will execute command1 in the background then command2 (in the foreground).

	command >&1

does not break '&' normal use because it is used in the twople '>&' that is,
no white space can be used between the '>' and the '&', thus no ambiguity.

I doubt the general usefullness of having the shell expand any sequence of
symbols to '/dev/stdin' (except in globbing: /dev/stdi* :-).  This seems
like a job for programable function keys or possibly a typing tutor :-).

Pax, Keith
-- 
ag at amix.commodore.com        Keith Gabryelski          ...!cbmvax!amix!ag



More information about the Comp.unix.questions mailing list