Skip to content

Latest commit

 

History

History
69 lines (49 loc) · 2.58 KB

ORGMODE.org

File metadata and controls

69 lines (49 loc) · 2.58 KB

Org Mode

https://orgmode.org/features.html

https://github.com/doomemacs/doomemacs/blob/master/modules/lang/org/config.el

Tutorials

  1. Getting started with Org-mode
  2. Org Mode Compact Guide
  3. Org Mode’s evil keybinding

Tips

Convert Markdown to Org Mode

# enter a shel with pandoc available
nix shell nixpkgs#pandoc
# convert markdown into orgmode
pandoc  --wrap=preserve --from markdown --to org README.md -o README.org

If you’re familiar with markdown, learn orgmode via pandoc convert is a good idea.

Special Symbols(Entities) & Escaping

https://orgmode.org/manual/Special-Symbols.html

When migrating from Markdown to Org Mode, I have a big headache about how to escape some special symbols.

Here are three methods I found to make things easier:

  1. Use the following syntax for multiline code.(use =,= at the start of lines inside the code block for escaping)
    #+begin_example
    ,,#+begin_example
    \alpha xxx \alpha
    ,,#+end_example
    #+end_example
        
  2. for one line code, colon followed by a space is a shortcut for #+begine_src ... #+end_src.
    : echo hello
        
  3. Use =this is good= or ~echo hello~ for inline code
    1. = or ~ can be used inside a inline code block too: =~this is good~= will show ~this is good~.
    2. NOTE: GitHub do not support ~~xxx~~ or ==xxx==, so if the content contains =, use ~ to quote it, and vice versa.
  4. Use LaTeX-like syntax to insert special symbols: A table of symbols for Org-mode
    1. For example, use \alpha to insert a α symbol.
    2. NOTE: If you do not want to add a space after the LaTex syntax, you have to add a {} after it,e.g. \alpha{}xxx will show αxxx
  5. Add #+OPTIONS ^:nil at the start of the org file, to disable
  6. Insert a zero-width Unicode character to break the text’s structure, so that the content won’t be recognized as some orgmode syntax.
    1. NOTE: I really don’t like using non-ASCII characters for escaping, it’s too tricky! An invisible space character can be a real headache at some point.

Mysteries

Still don’t know how to make orgmode render the following correctly:

  1. ~'a~ ⇒ ~’a~
  2. ='a= ⇒ =’a=
  3. Show only one comma at the start of the following lines(code).
    ,,#+begin_example
    \quotesinglbase{}xxx