I want to display all lines from one which match regular expression
if I have a file
foo
bar123
baz12435
lorem
ipsum
dolor
sit
amet
this display-from baz[0-9]* < file sould return (It doesn’t matter if it display matched line or not)
lorem
ipsum
dolor
sit
amet
How can I do this in Linux (with sed, awk or grep)
This will delete all lines from the input except the ones from the first line that matches the regex (/baz[0-9]*/) to the end of the file ($).