From mboxrd@z Thu Jan 1 00:00:00 1970 From: Aaron Ecay Subject: Re: Conditional link export? Date: Fri, 06 Nov 2015 13:26:31 +0000 Message-ID: <87611fuum0.fsf@gmail.com> References: <87ziyri8lk.fsf@gmail.com> <878u6buupy.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:41075) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zuh2L-0002p0-Qy for emacs-orgmode@gnu.org; Fri, 06 Nov 2015 08:26:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zuh2I-00049t-JY for emacs-orgmode@gnu.org; Fri, 06 Nov 2015 08:26:37 -0500 Received: from mail-wi0-x234.google.com ([2a00:1450:400c:c05::234]:33672) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zuh2I-00049e-ES for emacs-orgmode@gnu.org; Fri, 06 Nov 2015 08:26:34 -0500 Received: by wijp11 with SMTP id p11so30103530wij.0 for ; Fri, 06 Nov 2015 05:26:34 -0800 (PST) In-Reply-To: <878u6buupy.fsf@gmail.com> 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: Oleh Krehel , emacs-orgmode@gnu.org Hi again, 2015ko azaroak 6an, Aaron Ecay-ek idatzi zuen: > > Hi Oleh, > > One approach would be to use a parse-tree filter to change one kind of > link into another. Something like the following (not tested): > > ,---- > | (defun awe/change-info-links (tree backend _info) > | (org-element-map tree 'link > | (lambda (link) > | (when (org-export-derived-backend-p backend 'html) add (equal (org-element-property :type link) "info") to the condition of the when. derp derp derp, -- Aaron Ecay