[CS-FSLUG] Command line query

Josiah Ritchie jritchie at bible.edu
Fri Jan 21 10:26:34 CST 2005


On Fri, 2005-01-21 at 10:59 -0500, Stephen J. McCracken wrote:
> Josiah Ritchie wrote:
> > On Fri, 2005-01-21 at 10:26 +0800, Leon Brooks wrote:
> > 
> >>On Thursday 20 January 2005 19:59, Brian Derr wrote:
> >>
> >>>The following is what I've tried.
> >>
> >>>1.)  wget http://ed.asisaid.com/VnE.jpg | xv -
> >>
> >>wget -O- http://ed.asisaid.com/VnE.jpg | xv -
> >>
> >>By default wget writes the file to disk. -O- tells it to write to stdout 
> >>instead. You might also need -q or something to prevent banners and 
> >>progress information getting underfoot. Or not.
> > 
> > 
> > Is that the standard way to get a program to do that or is it wget
> > specific? I knew about - for pulling it from stdin, but don't remember
> > seeing that.
> 
> I was curious, too, so I looked it up:
> 
> excerpt from man wget:
> -O file
> --output-document=file
> The documents will not be written to the appropriate files, but all will 
> be concatenated together and written to file.  If file already exists, 
> it will be overwritten.  If the file is -, the documents will be written 
> to standard output.

I didn't read far enough into the description before... So in the -O-
the 2nd - is actually the parameter of the option -O. I'd conclude that
it could also be written '-O -' which is more intuitive/readable to me.
Is not using a space in things like this one of those programming tricks
to cut down on program size or just a preference?

JSR/





More information about the Christiansource mailing list