Link to home
Start Free TrialLog in
Avatar of ruby_srinivas
ruby_srinivas

asked on

Searching an Argument

Hi

I am using a more command on doing a search on a string argument.

Below is what I am doing

more "filename" |  grep "Argument"

But this is only giving me the specific argument only in the file.

What I want to do is I want to get the Argument and from there I want to move forward in the whole file

"that means I want to get argument and from there I should the start reading the file."

I hope I made by question clear.

Is there any command which allows me to do that..

Thanks

Ruby
ASKER CERTIFIED SOLUTION
Avatar of brettmjohnson
brettmjohnson
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial

Fire up more and use /string to find a string; note use just / to find the same string again. This / is a command - not the +/ option on the more command line.


$  more filename

/string


Cheers
JJ
Avatar of Gns
Gns

JJ, this is exactly the same ... The "+...." syntax is just to "jumpstart" more with a command... Completely analogous with other paginators... And it fits with the initial Q;-)

-- Glenn