Org Babel Translate
Translate text in Emacs’ org-mode blocks, like so:
This is a test. #+RESULTS: : Dies ist ein Test .
Or with multiple destination languages:
This is a test. #+RESULTS: | de | Dies ist ein Test . | | fr | Ceci est un essai . | | ar | هذا هو الاختبار. | | ja | これはテストです。 |
Installation
If you’re hooked up to MELPA:
M-x package-refresh-contents M-x package-install RET ob-translate
Alternatively just grab the single ob-translate.el
file and install that in your preferred way.
Status
Beta. It works for me, but I’ll bet there are some character encoding issues in there for some languages. Please file an issue if you spot a problem.
Options
Each block supports the following arguments:
Argument | Description | Example | Default |
---|---|---|---|
:src | Source language. | #+BEGIN_SRC translate :src de | ‘auto’ (for auto detection). |
:dest | Destination language(s). | #+BEGIN_SRC translate :dest it,fr | ‘en’ (for English). |
:dest
may be a single country-code, or a comma-separated list.
All defaults are customizable with M-x customize-group RET ob-translate
.