From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "yinglcs@gmail.com" Newsgroups: gmane.emacs.help Subject: setting up filecache and ido Date: Sun, 2 Nov 2008 23:12:07 -0800 (PST) Organization: http://groups.google.com Message-ID: <5915a45f-a1f3-4a2d-8489-d17f317eff9f@c22g2000prc.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1225698061 3096 80.91.229.12 (3 Nov 2008 07:41:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 3 Nov 2008 07:41:01 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Nov 03 08:42:04 2008 connect(): Connection refused Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Kwu4W-00018O-Oq for geh-help-gnu-emacs@m.gmane.org; Mon, 03 Nov 2008 08:42:01 +0100 Original-Received: from localhost ([127.0.0.1]:41185 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kwu3L-0005L2-1Y for geh-help-gnu-emacs@m.gmane.org; Mon, 03 Nov 2008 02:40:47 -0500 Original-Path: news.stanford.edu!newsfeed.stanford.edu!postnews.google.com!c22g2000prc.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 48 Original-NNTP-Posting-Host: 75.57.92.139 Original-X-Trace: posting.google.com 1225696327 7129 127.0.0.1 (3 Nov 2008 07:12:07 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Mon, 3 Nov 2008 07:12:07 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: c22g2000prc.googlegroups.com; posting-host=75.57.92.139; posting-account=21CglQoAAACb_-hBxAVv13ZLfdnJRfLv User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.3) Gecko/2008101315 Ubuntu/8.10 (intrepid) Firefox/3.0.3, gzip(gfe), gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:164026 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:59369 Archived-At: Hi, I am trying to following this: http://sachachua.com/wp/2008/07/27/eclipse-to-emacs-navigating-your-source-tree/#comment-103149 to setup my emacs with etag. But when I include the following in my emacs. emacs goes up to 100% cpu for > 5 minutes. Can you please tell me how can I fix my problem? Thank you. (require 'filecache) (require 'ido) (defun file-cache-ido-find-file (file) "Using ido, interactively open file from file cache'. First select a file, matched using ido-switch-buffer against the contents in `file-cache-alist'. If the file exist in more than one directory, select directory. Lastly the file is opened." (interactive (list (file-cache-ido-read "File: " (mapcar (lambda (x) (car x)) file-cache-alist)))) (let* ((record (assoc file file-cache-alist))) (find-file (expand-file-name file (if (= (length record) 2) (car (cdr record)) (file-cache-ido-read (format "Find %s in dir: " file) (cdr record))))))) (defun file-cache-ido-read (prompt choices) (let ((ido-make-buffer-list-hook (lambda () (setq ido-temp-list choices)))) (ido-read-buffer prompt))) (ido-mode t) ;; Change this to filter out your version control files (add-to-list 'file-cache-filter-regexps "\\.svn-base$") (if drupal-project-path (file-cache-add-directory-using-find drupal-project-path)) (global-set-key (kbd "ESC ESC f") 'file-cache-ido-find-file)