小编cma*_*rqu的帖子

突出显示缺少emacs缓冲区中的哪个文件名

在GNU Emacs中,我可以使用类似假设的"flyexist.el" - 我有一个带有绝对(Unix)文件名的缓冲区(加上一些附加文本).大多数这些文件存在,但有些文件丢失了.我想运行一个功能,突出显示我丢失的文件(可能有红色叠加).这个函数需要弄清楚缓冲区中的哪个文本看起来像文件名(一些误报是可以的),然后使用file-exists-p进行处理.

例如,假设我的缓冲区包含

Some random text mentioning /file/that/does/exist.txt, 
some more random text, and a /file/that/does/not-exist.txt
Run Code Online (Sandbox Code Playgroud)

我希望突出显示第二个文件.

这样的事情已经存在吗?

emacs overlay elisp highlighting

4
推荐指数
1
解决办法
553
查看次数

标签 统计

elisp ×1

emacs ×1

highlighting ×1

overlay ×1