Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!gatech!mcnc!xanth!john From: john@xanth.UUCP Newsgroups: comp.emacs Subject: Re: Some gnu questions Message-ID: <1347@xanth.UUCP> Date: Fri, 19-Jun-87 13:01:19 EDT Article-I.D.: xanth.1347 Posted: Fri Jun 19 13:01:19 1987 Date-Received: Sat, 20-Jun-87 10:35:33 EDT References: <359@esunix.UUCP> Organization: Old Dominion University, Norfolk Va. Lines: 26 In article <359@esunix.UUCP>, tlastran@esunix.UUCP (Tom LaStrange) writes: > 1. Is there an equivalent to auto-execute? I noticed something about > some language hooks but nothing about how to write my own language > sensitive bindings, any suggestions on easy ways to execute commands > when certain file extensions are read? (describe-variable 'auto-mode-alist) gives: Documentation: Alist of filename patterns vs corresponding major mode functions. Each element looks like (REGEXP . FUNCTION). Visiting a file whose name matches REGEXP causes FUNCTION to be called. In my .emacs I have: ; automatically load nroff-mode on .me files, etc. (private convention) (setq auto-mode-alist (append auto-mode-alist '(("\\.me$" . nroff-mode) ("^/tmp/post" . text-mode) ("^/tmp/fol" . text-mode)))) Hope this helps, and thanks to , our resident GNU-wizard. -- John Owens Old Dominion University - Norfolk, Virginia, USA john@ODU.EDU old arpa: john%odu.edu@RELAY.CS.NET +1 804 440 4529 old uucp: {seismo,harvard,sun,hoptoad}!xanth!john