본문 바로가기

프로그래밍/Linux

Delete lines which start with specific keyword in VI or VIM

If you want to delete lines which start with specific keyword

follow this procedure


let's say there is a document like that and you want to delete lines start with "He"


Input "g/^He/d" into command line then you can delete the lines you want to delete