【发布时间】:2018-03-14 14:29:45
【问题描述】:
我正在尝试从 Youtube 视频中提取转录文本并将其解析为文档以进行编辑。 我已经能够删除放置在其中的大部分 HTML 标记。但是,我想删除下面的代码,这是已经被解析成单个字符串的时间戳和偏移量。
我试过这个,但我不擅长正则表达式:
/^\d{2}\:\d{8}\"\>$/gm
在 Regex101 测试器 (https://regex101.com/r/a9wi2j/3/) 中,它可以工作,但在 EditPad 替换中,它不能。
EditPad 中的什么正则表达式会删除所有以 "> 以下结尾的行?
03:17197850">
that so if you have production staff you
03:21201780">
can create logins like that for them and
03:24204299">
then they have access to all the
03:25205739">
information and everything they need but
03:27207359">
they can't go in and adjust pricing on
03:30210060">
【问题讨论】:
-
去掉
>后面的反斜杠:(?m)^\d{2}\:\d{8}\">$ -
还是不行
-
原来的没发,新发的发了,请贴出来作为答案。
-
也许不是你想要的,但在 vim 中你可以做到
:g/">$/d -
vim 正则表达式在 Editpad 中不起作用