New to Linux and need the credit for my class to ensure a good grade but not sure on the cmd line to finish
I have created a data file called ".addr_book" in home directory plus a 'bin" directory . NOW this is what I am unsure of

I need to create a file called "lookup" (shell script) in the bin directory that when run should find matching entries (lines) from my $HOME/.addr_book file and display them. The output must be sorted using grep, sort and postional parameters but NOT read.. Can anyone help? Thanks in advance

New to Linux and need the credit for my class to ensure a good grade but not sure on the cmd line to finish
I have created a data file called ".addr_book" in home directory plus a 'bin" directory . NOW this is what I am unsure of

I need to create a file called "lookup" (shell script) in the bin directory that when run should find matching entries (lines) from my $HOME/.addr_book file and display them. The output must be sorted using grep, sort and postional parameters but NOT read.. Can anyone help? Thanks in advance

ADD ON: ok I think this is part of what I will place in the "look up" file but still need help with the positional parameters and if I need a sort option or just sort, please!
grep "Name" .addr_book |
ok from here I'm a little lost , how would sort work after the pipeline and the positional parameters. I figure if I can get the cmd right I can create the "look up" file in vi and place it there

Check the -k option of sort. That should help. (eg) if you want to sort based on 2'nd field,
ls -rlt | sort -k2

ALways check man sort. It mostly gives the best solution.

Regards,
Ranjith

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.