help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Using a File index


From: weber
Subject: Re: Using a File index
Date: 8 Feb 2007 04:26:12 -0800
User-agent: G2/1.0

On 8 fev, 03:44, Mathias Dahl <brakjol...@gmail.com> wrote:
> "HS" <hug...@gmail.com> writes:
> > That's nice, but it's solved now.
>
> How was it solved?

With this code:
(defun indexed-find (file)
  (interactive "MFilename: ")
  (find-file "my_file_index.txt")
  (if (re-search-forward (concat file " = ") nil t 1)
          (progn
                (setq beg (point))
                (end-of-line)
                (setq end (point))
                (find-file (buffer-substring beg end)))
          (message "File not found!"))
  (kill-buffer "my_file_index.txt"))

The index file was made with a ruby script, and I update it manually
when there are some new files...
Cheers,
HS



reply via email to

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