作者jamuqa (jamuqa)
看板Editor
標題[vim ] 在範圍內搜尋
時間Fri Jan 6 12:36:16 2012
假如我希望能在100行到200行內搜尋test字串
請問該怎麼做呢?
我現在都用取代方式做:100,200s/test//gc
但有更方便的方法嗎?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.120.49.163
1F:推 dm4: /\%>100l\%<200ltest 不過好像沒有比較方便…XD 01/06 12:55
2F:推 CrBoy:看你搜尋後要幹嘛吧?試試看 :100,200g/test/ ? 01/06 21:14
3F:推 Arton0306:原po應該是想像原本的search一樣可以highlight用nN來跳 01/06 22:09
5F:推 curist:用NrrwRgn :100,200NarrowRegion<cr> /test 01/08 11:49