How Do I Grep a Specific Line in Linux?
Contents How Do I Grep a Specific Line Number in Linux? the -N ( or –Line-Number ) Option Tells Grep to Show the Line Number of the Lines Containing a String...
Contents
How do I grep a specific line number in Linux?
The -n ( or –line-number ) option tells grep to show the line number of the lines containing a string that matches a pattern. When this option is used, grep prints the matches to standard output prefixed with the line number.
How do I search for a specific line in Linux?
To do this, go to Edit -> Preferences and tick the box that says “Display line numbers.” You can also jump to a specific line number by using Ctrl + I .