snosov1 / toc-org

toc-org is an Emacs utility to have an up-to-date table of contents in the org files without exporting (useful primarily for readme files on GitHub)
GNU General Public License v3.0
287 stars 29 forks source link

Don't export toc in LaTeX format #52

Closed thblt closed 6 years ago

thblt commented 6 years ago

Sorry if I'm missing something obvious, but I can't find a way to prevent the toc from being exported to LaTeX. Is there a way?

Thanks!

snosov1 commented 6 years ago

Hey!

You can add :noexport: tag to the toc heading (it's a standard way to prevent exporting). Does it work for you?

thblt commented 6 years ago

My mistake: I misunderstood my own problem :) I wanted a ToC in Github but I had assumed Github's renderer respected :noexport:, which it actually doesn't. So everything's fine indeed, :noexport:ing the ToC leaves it visible in Github. Thanks!

snosov1 commented 6 years ago

I had assumed Github's renderer respected :noexport:, which it actually doesn't.

Yup, that's the idea! Glad it works!

sangjeedondrub commented 1 year ago

Disable exporting the `toc'' generated bytoc-org' package.

(setq org-export-exclude-tags (quote ("noexport" "NOEXPORT" "hide" "HIDE" "TOC" "toc")))

Enable exporting `org-mode''s ``toc'' to LaTeX or HTML.

#+options: toc:t