2

Any quick way to export an org-mode document into a text file with no formatting and no org markup characters?

I am aware of C-c C-e [t] Export to Plain Text unfortunatly those options add formatting to the document

Header 1
═══════════════════════════════════

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do 
eiusmod tempor incididunt ut labore et dolore magna aliqua. 



Header2
────────────────────────────────────────

  ┌────
  │ code block
  └────

The format I'm looking for is:

Header 1

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do 
eiusmod tempor incididunt ut labore et dolore magna aliqua.

Header 2

code block
kevzettler
  • 327
  • 2
  • 13
  • What do you want to export exactly? org-mode documents are saved as raw text, if you open them up in another editor that's exactly what you'll see. In emacs, `M-x text-mode` or even `M-x fundamental-mode` will remove all syntax-highlighting and show you the raw text. – Tyler Feb 03 '17 at 22:10
  • I want to export all the text without any of the org-mode formatting characters. – kevzettler Feb 03 '17 at 22:26
  • 2
    I usually put the text in #+BEGIN_EXAMPLE and #+END_EXAMPLE block for no org-mode interference. – Emacs User Feb 03 '17 at 22:47

1 Answers1

3

You could try pandoc, e.g. with ox-pandoc. The command line would be like this:

pandoc -t plain -o outfile.txt YOUR_ORG_FILE.org

The output is:

HEADER 1


Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua.


Header 2

    code block
tarleb
  • 453
  • 4
  • 7