Getting all the lines containing a specific string from a Text File in windows

Posted on


I have a text file on my windows machine. I have a matching string. Say “check_time”.

I need to get all the lines which have these strings and copy them in a separate file. Only the lines matching this string should be copied. Since, it is a huge log file, searching with CTRL + F is not possible.


Check out built-in findstr command.

Leave a Reply

Your email address will not be published. Required fields are marked *