From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rafal Subject: Links to C/C++ source code lines Date: Thu, 13 Oct 2011 15:44:18 +0000 (UTC) Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([140.186.70.92]:45120) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1REOPG-0001SA-Fy for emacs-orgmode@gnu.org; Thu, 13 Oct 2011 12:45:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1REOPA-0007F2-U8 for emacs-orgmode@gnu.org; Thu, 13 Oct 2011 12:45:18 -0400 Received: from lo.gmane.org ([80.91.229.12]:56129) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1REOPA-0007Et-P0 for emacs-orgmode@gnu.org; Thu, 13 Oct 2011 12:45:12 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1REOP6-0000iC-B8 for emacs-orgmode@gnu.org; Thu, 13 Oct 2011 18:45:08 +0200 Received: from gate-il27-2.motorola.com ([136.182.2.26]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 13 Oct 2011 18:45:08 +0200 Received: from rafflo by gate-il27-2.motorola.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 13 Oct 2011 18:45:08 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi, I wrote a small hook for creating org-mode links to C/C++ source code lines in the form of a regexp so the links stay valid even if the source code changes eg. a source line while(ptr < ptr_end) has a link file:/home/user/src/example.cpp::/while[ \t]*([ \t]*ptr[ \t]*<[ \t]*ptr_end[ \t] *)#1/ The number after the hash is a sequence number in case there are more than one such line If you are interested: http://rafflo.w.interia.pl/org-c-link.el regards, Rafal