0
votes
0
comments
1,215
views

grep files from list

0 votes, 0.00 avg. rating (0% score)
I am trying to run grep against a list of a few hundred files: $ head -n 3 <(cat files.txt) admin.php ajax/accept.php ajax/add_note.php However, even though I am grepping for a string that I know is found in the files, the following does not search the files: $ grep -i 'foo' <(cat files.txt) $ grep […]
0
votes
0
comments
1,210
views

grep inside less?

0 votes, 0.00 avg. rating (0% score)
I’m currently sifting through a lot of unfamiliar logs looking for some issues. The first file I look at is Events.log, and I get at least three pages in less which appear to display the same event at different times – an event that appears to be fairly benign. I would like to filter this […]
0
votes
0
comments
2,759
views

Oneliners: Removing blank lines from a unix file

0 votes, 0.00 avg. rating (0% score)
Many of times I receive comma delimited files an they have blank lines after each record. I would like to use sed or awk. I need to remove all the blank lines from an input file and write into an output file.