On Wed, Jan 11, 2006 at 01:45:38PM +0000, MJ Ray wrote:
"Keith Watson" keith.watson@kewill.com
However I went with the $(cat filename) option as it seemed IMO a little more elegant to use the shell's built in features rather than a separate program (but that's just a personal bit of lunacy :-) )
Try $(< filename) and use the shell's built-in features to avoid the gratuitous use of cat, as mentioned in man bash. You'll need xargs if you have too many things for one command line, I think.
That also works for multiline files... changing them in to space seperated args like a nice little shell.
$ cat test blip blat blop $ echo $(<test) blip blat blop $
I'd still go the xargs route though :)
Cheers,