Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我是 Emacs/Aquamacs 的新手,想用它在 Prolog 中编程。我的文件名以“.pl”结尾,Aquamacs 自动假定它是一个 Perl 文件。如何将其更改为使用 Prolog 模式?我更喜欢一个不假设我知道如何在 Emacs 中解决问题的答案。
在首选项 -> 编程 -> 语言下。我找不到 Prolog,即使 Aquamacs 网页声明它应该支持 Prolog?我需要安装一些插件吗?
您可以使用 手动激活 Prolog 模式M-x prolog-mode。
我的 Emacs 配置文件中有以下行(通常称为.emacs,尽管我个人使用替代位置.emacs.d/init.el)使其成为.pl文件的默认值:
.emacs
.emacs.d/init.el
.pl
(add-to-list 'auto-mode-alist '("\\.pl\\'" . prolog-mode))