all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Kevin Rodgers <kevin.d.rodgers@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: custom rgrep with multi dirs
Date: Mon, 16 Jun 2008 23:26:21 -0600	[thread overview]
Message-ID: <g37htk$que$1@ger.gmane.org> (raw)
In-Reply-To: <60b54c04-6aa9-4efe-8406-8566dfa07843@u12g2000prd.googlegroups.com>

Xah wrote:
> I have this function:
> 
> (defun xah-find-word-usage (myword)
>   "Grep a dir for a word's usage."
>   (interactive "sWord to search: ")
>   ;;(require 'grep)
>   (rgrep myword "*\\.html" "~/web/p")
> )
> 
> However, if i call if for the first time, i get
> “grep-expand-template: Wrong type argument: stringp, nil”.
> 
> But if i have used rgrep before in this session, then it works.
> 
> I guess i need the (require 'grep) but that didn't help. Any hints?

Just a guess: call grep-compute-defaults in your interactive form,
just like all the commands defined in grep.el.

-- 
Kevin Rodgers
Denver, Colorado, USA





  reply	other threads:[~2008-06-17  5:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-14  9:31 custom rgrep with multi dirs Xah
2008-06-16 15:26 ` Xah
2008-06-17  5:26   ` Kevin Rodgers [this message]
     [not found]   ` <mailman.13435.1213680387.18990.help-gnu-emacs@gnu.org>
2008-06-17  6:50     ` Xah

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='g37htk$que$1@ger.gmane.org' \
    --to=kevin.d.rodgers@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.