User Tools

Site Tools


sed:print

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
sed:print [2020/08/17 08:55] 192.168.1.1sed:print [2020/12/22 16:05] (current) peter
Line 1: Line 1:
 ====== SED - Print ====== ====== SED - Print ======
 +
 +[[SED:Print:Print|Print]]
  
 [[SED:Print:Print 1 line of context before and after regexp, with line number indicating where the regexp occurred|Print 1 line of context before and after regexp, with line number indicating where the regexp occurred]] [[SED:Print:Print 1 line of context before and after regexp, with line number indicating where the regexp occurred|Print 1 line of context before and after regexp, with line number indicating where the regexp occurred]]
 +
 +[[SED:Print:Print a random line|Print a random line]]
  
 [[SED:Print:Print a specific line number|Print a specific line number]] [[SED:Print:Print a specific line number|Print a specific line number]]
 +
 +[[SED:Print:Print all of file EXCEPT section between 2 regular expressions|Print all of file EXCEPT section between 2 regular expressions]]
  
 [[SED:Print:Print every Nth line|Print every Nth line]] [[SED:Print:Print every Nth line|Print every Nth line]]
Line 10: Line 16:
  
 [[SED:Print:Print first N lines of a file|Print first N lines of a file]] [[SED:Print:Print first N lines of a file|Print first N lines of a file]]
 +
 +[[SED:Print:Print last line of a file|Print last line of a file]]
 +
 +[[SED:Print:Print last 2 lines of a file|Print last 2 lines of a file]]
 +
 +[[SED:Print:Print last N lines of a file|Print last N lines of a file]]
 +
 +[[SED:Print:Print line immediately after a regexp, but not the line containing the regexp|Print line immediately after a regexp, but not the line containing the regexp]]
 +
 +[[SED:Print:Print line immediately before a regexp, but not the line containing the regexp|Print line immediately before a regexp, but not the line containing the regexp]]
  
 [[SED:Print:Print lines of N characters or longer|Print lines of N characters or longer]] [[SED:Print:Print lines of N characters or longer|Print lines of N characters or longer]]
Line 17: Line 33:
 [[SED:Print:Print lines which match a regular expression|Print lines which match a regular expression]] [[SED:Print:Print lines which match a regular expression|Print lines which match a regular expression]]
  
-[[SED:Print:Print only lines which match regular expression|Print only lines which match regular expression]] +[[SED:Print:Print lines which do NOT match regexp|Print lines which do NOT match regexp]]
- +
-[[SED:Print:Print only lines which do NOT match regexp|Print only lines which do NOT match regexp]]+
  
 [[SED:Print:Print paragraph if it contains string|Print paragraph if it contains string]] [[SED:Print:Print paragraph if it contains string|Print paragraph if it contains string]]
Line 27: Line 41:
 [[SED:Print:Print paragraph if it contains string1 or string2 or string3|Print paragraph if it contains string1 or string2 or string3]] [[SED:Print:Print paragraph if it contains string1 or string2 or string3|Print paragraph if it contains string1 or string2 or string3]]
  
-[[SED:Print:Print section of file based on line numbers|Print section of file based on line numbers]]+[[SED:Print:Print section of file based on a range of line numbers|Print section of file based on a range of line numbers]]
  
-[[SED:Print:Print section of file from regular expression to end of file|Print section of file from regular expression to end of file]]+[[SED:Print:Print section of file between two regular expressions (inclusive)|Print section of file between two regular expressions (inclusive)]]
  
-[[SED:Print:Print the last line of file|Print the last line of a file]] +[[SED:Print:Print section of file from regular expression to end of file|Print section of file from regular expression to end of file]]
- +
-[[SED:Print:Print the last 2 lines of a file|Print the last 2 lines of file]] +
- +
-[[SED:Print:Print the last N lines of a file|Print the last N lines of file]]+
  
-[[SED:Print:Print the line immediately after a regexp, but not the line containing the regexp|Print the line immediately after a regexp, but not the line containing the regexp]] 
  
-[[SED:Print:Print the line immediately before a regexp, but not the line containing the regexp|Print the line immediately before a regexp, but not the line containing the regexp]] 
  
sed/print.1597654544.txt.gz · Last modified: 2020/08/17 08:55 by 192.168.1.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki