2

I'm having a problem with changing a directory in which I store *.pl files. The default one is located in my home folder. I can change working directory, either by using working_directory predicate or cd command in swipl interpreter. The thing is I have to do it every single time I run SWI Prolog, so I'm looking for a permanent solution. I tried to include those two solutions in .plrc file, which I created in my home directory but it didn't help.

I am a Mac OS X user, if that would be of any help.

Also, can you recommend any text editors for Prolog with multi-tabs support?

4

1 回答 1

3

SWI-Prolog 支持每个用户的初始化文件,在 MacOS X 等 POSIX 系统上,该文件名为.plrc. 只需在您的主目录中创建此文件(如果它不存在)并添加以下行:

:- initialization(cd).

关于为 Prolog 提供多选项卡和语法着色支持的文本编辑器,请尝试 TextMate 2(安装了 Prolog 或 Logtalk 包)。

于 2013-09-10T13:09:56.543 回答