Textmate 正则表达式问题

Textmate Regex Issue

我有一个非常大的 .CSV 文档,其中包含我需要删除的文本。数据看起来像这样

774431994&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774431994

774431996&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774431996

774431998&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774431998

774432000&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774432000

774432003&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774432003                

774432006&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774432006

774432009&images=774431994,774431996,774431998,774432000,774432003,774432006,774432009&formats=0,0,0,0,0 /1/6/9/5/2/6/8/webimg/774432009

我正在使用以下正在处理 http://regexr.com/3a6oa

的正则表达式
/.{128}(?=webimg).{10}/g

它似乎不适用于 Textmate 搜索。有谁知道为什么?我需要 select 所有这些垃圾并用任何东西替换它,每次的数字都是唯一的。

非常感谢

  • 为什么要在模式中使用前瞻?只需使用:/.{128}webimg.{10}/g

  • 您为什么要使用 Textmate 搜索?我需要知道问题的更多上下文才能确定,但​​我敢打赌,可以使用一个简单的 sed 命令来代替:

sed -i "webimg/d" ./filename.csv