参考:http://stackoverflow.com/questions/19177721/extract-lines-between-two-patterns-from-a-lfile
awk ‘/pattern1/ {p=1}; p; /pattern2/ {p=0}‘ file
linux to extract contents between patterns
时间: 2024-11-01 12:31:38
参考:http://stackoverflow.com/questions/19177721/extract-lines-between-two-patterns-from-a-lfile
awk ‘/pattern1/ {p=1}; p; /pattern2/ {p=0}‘ file
linux to extract contents between patterns