[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dir-specific grep-find-command?

From: Kevin Rodgers
Subject: Re: dir-specific grep-find-command?
Date: Fri, 20 Jun 2003 09:07:39 -0600
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv: Gecko/20020406 Netscape6/6.2.2

Ed L Cashin wrote:

Kevin Rodgers <address@hidden> writes:
(add-hook 'find-file-hooks 'in-kernel-hook)
(add-hook 'dired-mode-hook 'in-kernel-hook)

Excellent!  That seems to do exactly what I wanted.

Did you already know about those hooks or did you just know how to
find them, because I guess I failed to find them.

After 20 years of using Emacs, I just knew about them.

But all conventional modes have a hook, so dired-mode-hook should have
been obvious.  And then rather than trying to predict what kind of files
might be in your kernel directory structure (i.e. what modes might be
used and thus hooks might need to be added to), the standard hook to use
is find-file-hooks (and find-file-not-found-hooks for new files).

<a href="mailto:&lt;kevin.rodgers&#64;;";>Kevin Rodgers</a>

reply via email to

[Prev in Thread] Current Thread [Next in Thread]