..one way to do this is to use "tput" and "terminfo" capabilities, if these are available. terminfo allows for the definition of colour attributes, and tput can access those definitions.
"tic" and "infocmp" are the methods used to compile and discover...
from memory .. this works if file_name is fully qualified (such as /usr/local/bin/myprocess); if you want the shell to do a PATH search, then you probably need to use execvp.
&argv[1] looks OK and can be any length, providing argv is terminated by a null pointer. This is true if you are simply...
..this is a bigger challenge than it first appears. On closer inspection, the real problem is that for a master file of 7,000 records and a data file of 1 million records, these solutions will produce 7 thousand million reads - a lot of activity and time whatever your cpu/disk combo. Perhaps a...
.. you could try grep (or one of it's flavours such as egrep or fgrep) which is a utility geared specifically to pattern matching:
grep $i filename >resultfile
see "man grep" for various interesting options
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.