/docs/MyDocs

To get this branch, use:
bzr branch http://darksoft.org/webbzr/docs/MyDocs

« back to all changes in this revision

Viewing changes to Development/languages/bash/sed.txt

  • Committer: Suren A. Chilingaryan
  • Date: 2015-08-21 03:52:00 UTC
  • Revision ID: csa@suren.me-20150821035200-xu1zh22cqlk2omcq
Profiling

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
 
 
3
Samples
 
4
=======
 
5
ps -efl | sed '1p; /pci/!d'                                     - Print first line and lines matching the expression
 
6
                                                                for each line: 
 
7
                                                                    we check if line first, we print it
 
8
                                                                    if line does nto match the regexp, we delete it from pattern space and continue to next line
 
9
                                                                    the rest we print
 
10