我有一个 SGML 文件,它看起来有很多<p>
带有隐含结束标签的段落,如下所示:
<p>Here is one paragraph.
<p>And here is another. This one contains <i>italics</i>.
<p>Finally, here is another paragraph.
这些段落没有结束标签。我想让它看起来像这样:
<p>Here is one paragraph.</p>
<p>And here is another. This one contains <i>italics</i>.</p>
<p>Finally, here is another paragraph.</p>
有没有使用 OSS 工具的简单方法来做到这一点?(如 vim、sed 等?)