From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: Should comments break paragraphs? Date: Wed, 17 Jul 2013 21:18:48 +0100 Message-ID: <87vc49549j.fsf@ucl.ac.uk> References: <51E443F6.2050104@arfer.net> <87mwpnfybn.fsf@gmail.com> <51E47BC1.7010808@gmail.com> <87ip0byoqg.fsf@gmail.com> <87fvvev771.fsf@gmail.com> <87wqoqxznb.fsf@gmail.com> <87ppuitp8y.fsf@gmail.com> <87sizexuj9.fsf@gmail.com> <87li55lpqd.fsf@bzg.ath.cx> <87mwplk645.fsf@gmail.com> <87fvvdk3es.fsf@bzg.ath.cx> <87ip09k1d4.fsf@gmail.com> <878v15jqdy.fsf@bzg.ath.cx> <87ehaxjo2m.fsf@gmail.com> <874nbt6n12.fsf@ucl.ac.uk> <8738rdj9ei.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:53930) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UzYBb-0006K7-Ua for emacs-orgmode@gnu.org; Wed, 17 Jul 2013 16:18:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UzYBa-0000bl-IV for emacs-orgmode@gnu.org; Wed, 17 Jul 2013 16:18:55 -0400 Received: from mail-db9lp0249.outbound.messaging.microsoft.com ([213.199.154.249]:5637 helo=db9outboundpool.messaging.microsoft.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UzYBa-0000bb-9N for emacs-orgmode@gnu.org; Wed, 17 Jul 2013 16:18:54 -0400 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: Nicolas Goaziou Cc: emacs-orgmode@gnu.org Nicolas Goaziou writes: > Hello, > > Eric S Fraga writes: > >> This little snippet works just fine for comment lines. However, I tried >> changing the regexp to one that matches an :ignoreheading: tag on a >> headline. This works when I do a LaTeX export but not an HTML one. Why >> would the behaviour be different in each case? > > It shouldn't. Would you mind sending your hook? Actually, it works so sorry about the noise. I just tried emacs -Q and realised that one of my other customisations was getting in the way. For the record, this is what I have which (almost) does what I want: #+begin_src emacs-lisp (defun esf/remove-lines-with-ignore-heading-tag (backend) (message "Deleting lines with ignore heading tag") (delete-matching-lines "^\\*+.*[ \t]+[a-ZA-Z0-9:]*:ignoreheading:[a-ZA-Z0-9:]*$")) (add-hook 'org-export-before-processing-hook 'esf/remove-lines-with-ignore-heading-tag) #+end_src I say almost because I actually want to replace matching lines by "\n" and not simply delete them (sort of going against the whole thread... ;-). But I'll figure this bit out -- good emacs lisp practice for me! thanks, eric -- : Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.1, Org release_8.0.5-337-g9f3bed