Paul Mead <paul.d.m...@gmail.com> writes: > is there any way of excluding just a heading from export, whilst exporting > the text below it in the usual way? If I use :noexport: it does what it > says in the documentation - prevents the entire subtree from exporting. > > For my current work though, I'd like to use headings to rough out a > structure write notes - noexport is fine for this. Then in each section > I want to export the final 'written up' version. I can separate those > with different headings, but don't want the headings to show up in the > exported text. > > Example: > > * Essay title > ** Notes on paragraph 1 :noexport: > These are notes which I want to remain hidden, including the heading > ** Paragraph 1 > This is the text I want to see exported, but I don't want the heading >
One hack would be to use an export hook to remove headings with a particular tag. E.g., --8<---------------cut here---------------start------------->8--- (defvar my-org-export-remove-heading-tag "killtag") (defun my-org-export-remove-headings-with-tag () (while (re-search-forward (concat ":" my-org-export-remove-heading-tag ":") nil t) (beginning-of-line) (kill-line))) (add-hook 'org-export-preprocess-after-tree-selection-hook 'my-org-export-remove-headings-with-tag) --8<---------------cut here---------------end--------------->8--- Best, Matt _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode