This Emacs mode for ACT-R provides syntax highlighting, and identifier menu (for production rules) and some smart-editing features (i.e., auto indenting for production rules).
This mode was only tested with GNU Emacs 21.3.50.4.
Copy the file actr-mode.el in a directory that appears in your load-path variable. If you don't know about such a directory or variable, create a directory (for example named "~/emacs-lisp" if you're on a Unix system), copy the actr-mode.el file in that directory, and add the following lines to your .emacs:
(setq load-path (append '("~/emacs-lisp") load-path))
By adding the following line to your .emacs:
(require 'actr-mode)
Emacs will automatically enable actr-mode when you open a file that ends in .actr or .act.
The user defineable code (e.g., what colors to use for the highlighting) is at the top of the actr-mode.el file.
To see what the actr-mode does, open an ACT-R model file (if it doesn't have an extention of either .act or .actr, type M-x actr-mode [enter] to enable actr-mode), and start creating a new production rule. Instead of using spaces, just press tab once. For example:
(p test[enter] [tab]=goal>[enter] [tab]slot0[tab]value[enter] [tab]- slot1[tab]value[enter] [tab]=visual>[enter] [tab]==>[enter]
will create a production rule that looks like:
(p test
=test>
slot0 value
- slot1 value
=visual>
==>
and then of course color coded but I am to lazy to figure out how to do that in HTML. :-)
Let me know if something doesn't work as expected. The previous version of the actr-mode was quite a bit more extensive. However, is I didn't use most of the functionality of the old version, I've removed that from this version. This change, together with the changes to account for the new ACT-R 5 syntax, has probably introduced some new bugs. So, please let me (see below for the email address) know if something doesn't work as expected.