From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Fast linking to files in private git repos through a hyperlink Date: Fri, 20 Apr 2012 14:01:25 +0200 Message-ID: <87k41awr1m.fsf@altern.org> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:33172) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SLCVh-0006vS-8y for emacs-orgmode@gnu.org; Fri, 20 Apr 2012 08:00:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SLCVb-0008GT-VF for emacs-orgmode@gnu.org; Fri, 20 Apr 2012 08:00:20 -0400 Received: from mail-we0-f169.google.com ([74.125.82.169]:46160) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SLCVb-0008EW-KV for emacs-orgmode@gnu.org; Fri, 20 Apr 2012 08:00:15 -0400 Received: by werj55 with SMTP id j55so7814195wer.0 for ; Fri, 20 Apr 2012 05:00:13 -0700 (PDT) In-Reply-To: (Dov Grobgeld's message of "Thu, 19 Apr 2012 14:24:23 +0300") 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: Dov Grobgeld Cc: emacs-orgmode Hi Dov, Dov Grobgeld writes: > I thought I would share the following hack that I did with git. > > In my org-mode notebook I often find myself references files that > reside in various private git repos. So far I have referenced these > either by just writing their name or giving a full path. But giving > the full path is disruptive and if the repo moves it will no longer > work. So I added a hack to make the following hyperlink work > git:myrepo::myfile . When opening it the following happens: > > - myrepo is looked up in the emacs hash my-git-repos and mapped to > the path of a git repo root. > - git-find-file-in-repo searches for the the file myfile in the the > repo repo > > Here's the code for org-git-hyperlink.el: Nice. Can you try to merge these features with contrib/lisp/org-git-link.el from the current repo? Thanks! -- Bastien