71 KiB
Summary
This How-To
tutorial provides a step by step guide on how to migrate the LaTeX template provided by an academic journal into org-mode
syntax.
Instructions
To complete this tutorial successfully, please follow all steps in the order presented of each section listed below:
- Requirements
- Create New
org-mode
File - Download LaTeX Template
- Migrate LaTeX Template Code into
local variables
- Migrate LaTeX Template Code into
SRC
blocks - Customize a
SRC
block using Literate Programming - Add Content to
org-mode
File - Export completed
org-mode
file asPDF
Requirements
Note: All the requirements must be completed successfully before continuing with the steps in this
How-To
tutorial.
Instructions
- Download, Install, and Configure LaTeX Software
Unfortunately, this requirement is beyond the scope of this
How-To
tutorial. - Download, Install, and Configure
emacs
Software Unfortunately, this requirement is beyond the scope of thisHow-To
tutorial. -
Download, Install, and Configure
org-mode
SoftwareNote: The
org-mode
application is already installed if you are using a recent version ofemacs
, i.e. versions 25 or greater.Unfortunately, this requirement is beyond the scope of this
How-To
tutorial. -
Export an
org-mode
file asPDF
via built-in LaTeX exporter.TIP: To export an
org-mode
document toPDF
:- Open the
org-mode
file inemacs
. - Position the cursor in the buffer of the
org-mode
document inemacs
. - Press the following key chords and keys,
C-c
C-e
l
p
to initiate the export process. - Open the exported
PDF
file to validate the export process succeeded.
If exporting an
org-mode
file toPDF
succeeded then continue following the steps in thisHow-To
tutorial. Otherwise troubleshoot each step in the requirements section and repeat until exporting anorg-mode
document toPDF
is successful. - Open the
Create New org-mode File
Instructions
-
Create a new
org-mode
file usingemacs
.For this tutorial, the filename will be
journal-template.org
-
To create the file in emacs do the following:
- Press the key chords
C-x
C-f
- Type
journal-template.org
- Press
Return
orEnter
key
- Press the key chords
-
-
Add
mode
line to top of the file.# -*- mode: org; org-confirm-babel-evaluate: nil; org-babel-noweb-wrap-start: "«"; org-babel-noweb-wrap-end: "»"; -*-
TIP: To insert
«
press key chordC-x
8
<
and to insert»
press key chordC-x
8
>
-
Add Template Utility Code Section to end of file.
* Template Utility Code :noexport:
-
Add Common Export Settings Section to end of the file.
* Common Export Settings :noexport: #+OPTIONS: ':nil *:t -:t ::t <:nil H:4 \n:nil ^:{} arch:headline #+OPTIONS: author:nil broken-links:nil c:nil creator:nil #+OPTIONS: d:(not "LOGBOOK") date:nil e:t email:nil f:t inline:t num:nil #+OPTIONS: p:nil pri:nil prop:t stat:nil tags:t tasks:nil tex:t #+OPTIONS: timestamp:nil title:nil toc:nil todo:nil |:t #+SELECT_TAGS: export #+EXCLUDE_TAGS: noexport nolatex # For Display when file is exported with org-ruby #+EXPORT_SELECT_TAGS: export #+EXPORT_EXCLUDE_TAGS: noexport
-
Save the file in
emacs
.-
To save the file in emacs do the following:
- Press the key chords
C-x
C-s
- Press the key chords
-
Self Check - Example 1
After completing the instructions in this section, the contents of journal-template.org should be similar to self-check-example-01.org.
Download LaTeX Template
For this How-To
tutorial, the LaTeX template1 provided by the European Physical Journal A (EPJ A)2 will be used.
The following 3 files provided by the EPJ A will be needed in this tutorial:
- template.tex
The
template.tex
file is provided as "[a] fill-in-form for a standard article with usage comments"3. The objective of thisHow-To
tutorial is migrate LaTeX code fromtemplate.tex
into the neworg-mode
file. - svepj.clo
The
svepj.clo
is the LaTeX "[c]lass option file for The European Physical Journal"4. - svjour.cls
The
svjour.cls
is the LaTeX "[c]ore document class file for Springer journals"5.
Instructions
-
Download template.tex file into same directory as
journal-template.org
. -
Download svepj.clo file into same directory as
journal-template.org
. -
Download svjour.cls file into same directory as
journal-template.org
.