Save yourself a lot of typing when you have to perform repetitive
commands on a list of files. Put the list of files in a text file
with one file per line ie: find . -name version.C > filename
Then have xargs build a command line for each file in the list as
follows:
cat filename |xargs -n 1 cp anotherfile
This will copy anotherfile over all the files listed in
filename one at a time until the end of filename is reached. NOTE: All tips provided are USE AT YOUR OWN RISK. Tips are submitted
by various unix admins around the globe. UGU suggest you read and
test each tip in a non-volitile environment before placing into
production.
LAST 5 TIPS
4587
- Suppose we want to check whether the web server is running or