最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

regex - How to ignore a NEW line completely matching to winmerge line filters? - Stack Overflow

programmeradmin3浏览0评论

I have two flat text (RTF) files whereas the one has some NEW lines, which however completely match to the filters, so the attempt is to ignore them.

One file:

...
\\pard\\plain\\intbl\\sb10\\sa10\\ql\\f1\\fs18\\cf1{\\cell}
{\\row}
\\pard}}{\\upr{\*\\bkmkstart IDX}{\*\\ud{\*\\bkmkstart IDX}}}{\*\\bkmkend IDX}\\trowd\\trkeep\\trhdr\\trqc
...

The other file:

...
\\pard\\plain\\intbl\\sb10\\sa10\\ql\\f1\\fs18\\cf1{\\cell}
{\\row}
\\trowd\\trkeep\\trql
{\\row}
\\pard}}{\\upr{\*\\bkmkstart IDX}{\*\\ud{\*\\bkmkstart IDX}}}{\*\\bkmkend IDX}\\trowd\\trkeep\\trhdr\\trqc\
...

See as in WinMerge: WinMerge compare New rows

The filters are:

{\\row}
\\trowd\\trkeep\\trql

I tried several options, like "Ignore blank lines" and/or "Enable move block detection".

WinMerge may only apply Regex on single lines, right? So, I also tried to tweak the filters a bit, as:

{\\row}\n
\\trowd\\trkeep\\trql\n

without success.

But, I would think in those cases, when the whole New line matches, then I think it should be possible to somehow omit those from the compare in some scenarios?

The only thing I would think of now, is to write a script to get rid of these extra lines and use these intermediate versions for WinMerge, then?

Any other idea?

Thanks in advance.

发布评论

评论列表(0)

  1. 暂无评论