From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Pascal Bourguignon Newsgroups: gmane.emacs.help Subject: Re: emac in large projects Date: Mon, 19 Feb 2007 19:58:29 +0100 Organization: Informatimago Message-ID: <871wkm7z56.fsf@thalassa.informatimago.com> References: <1171900635.549711.91890@m58g2000cwm.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1171914156 22793 80.91.229.12 (19 Feb 2007 19:42:36 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 19 Feb 2007 19:42:36 +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 Feb 19 20:42:29 2007 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 1HJEP6-0005SL-Ed for geh-help-gnu-emacs@m.gmane.org; Mon, 19 Feb 2007 20:42:28 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HJEP6-0002xJ-9h for geh-help-gnu-emacs@m.gmane.org; Mon, 19 Feb 2007 14:42:28 -0500 Original-Path: shelby.stanford.edu!headwall.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 40 Original-X-Trace: individual.net +zZVNE8/vskzaIYi3xvcCQTVJqJwErEXHS9E26hCMw+D5pfOEU Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en X-Disabled: X-No-Archive: no User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux) Cancel-Lock: sha1:hq2GAo/zR+ClYOsKRdPN9J/NUGo= Original-Xref: shelby.stanford.edu gnu.emacs.help:145720 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:41325 Archived-At: "Ask" writes: > I am a new learner of Emacs. How is it used for large projects. At > least, how do we find all occurrences of a function, how do we jump to > definition of a variable or function. There are other tools to do that > - gid, cscope etc. Can it be done from within the emacs editor > itself ? There are add-on IDE's. For example, have a look at http://cedet.sourceforge.net for C/C++ development, or at http://common-lisp.net/project/slime for Common Lisp development. For the specific feature you ask, you can build a TAGS file for your project, scanning all the source and header files with the etags command, and using the find-tag command (M-.) to find definitions, etc. For example, I put this target in my Makefile: etags tags: find $$(pwd) \( -name \*.lisp \ -o -name \*.[hc] \ -o -name \*.hh -o -name \*.cc \ \) -print | etags - M-x tags-reset-tags-table RET M-x compile RET tags RET Then I type the name of a function and M-. it asks for confirmation of the name of the function, and for the path to the TAGS file built by make tags above, (the first time after a tags-reset-tags-table), and the goes to the definition. -- __Pascal Bourguignon__ http://www.informatimago.com/ HEALTH WARNING: Care should be taken when lifting this product, since its mass, and thus its weight, is dependent on its velocity relative to the user.