Lets say I have the following text file
Code:
name
john123
phone:
123-213-4566
name
chris035
phone:
236-555-6546
name
bob56
phone:
333-666-9852
is there a way to find all the line that have "phone" and print them and the next line to make the out put look like this:
Code:
phone:
123-213-4566
phone:
236-555-6546
phone:
333-666-9852
I've looked into using grep awk & sed
I'm sure there is a way but I have yet to find it.