Skip to content

Latest commit

 

History

History
63 lines (49 loc) · 1.93 KB

README.org

File metadata and controls

63 lines (49 loc) · 1.93 KB

Sphinx layer

img/sphinx.png

Table of Contents

Description

The layer adds support for the documentation generation system Sphinx to the restructuredtext layer.

Features:

  • Support for Sphinx project compilation
  • Support for opening Sphinx project target
  • Support for opening Sphinx config file

Install

To use this configuration layer, add it to your ~/.spacemacs. You will need to add sphinx to the existing dotspacemacs-configuration-layers list in this file.

Configuration

Sphinx target

To use the layer’s Sphinx feature, the following variables should be set.

A parent directory is needed for all Sphinx projects’ builds.

(setq rst-sphinx-target-parent "/your/path/of/build/")

Set a directory in the parent directory for each Sphinx project.

(setq rst-sphinx-target-projects
      '(("project1" . (latex "folder/in/target/parent" t))
        ("project2" . (html  "folder/in/target/parent" nil))
        ))

Web browser

Set the browser for viewing the HTML page of current rst file. This one is optional. If not set, the default browser will be used.

(setq rst-slides-program "chromium")

Key bindings

Key bindingDescription
<SPC> m c ccompile projects
<SPC> m c Cclean projects
<SPC> m c rrebuild projects
<SPC> m g copen conf.py of current project
<SPC> m oopen compiled HTML page of current page